You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Chrome version 91.0.4472.114 (Official Build) (64-bit)
What operating system are you using?
Windows 10 Home (64-bit)
How are you deploying your application?
next dev/next build
Describe the Bug
When running next build or next start the configured next-env.d.ts gets overwritten and all configurations are removed. I'm using the next-page-transitions package to add transition effects on navigation but when I import the package typescript yells that no type definitions found for package next-page-transitions.
To solve this I added custom type declarations for the next-page-transitions and .svg files, by doing so my next-env.d.ts files looks like this.
BTW I'm using the yarn package manager and using the yarn run dev and yarn run build commands. Due to this bug, I have to rewrite the file every time I need to start the server.
Expected Behavior
Should not overwrite the type declaration file.
To Reproduce
Just initialize a new Next.js project with yarn create next-app --typescript and add type declarations for packages in next-env.d.ts file or follow up using this repository
The text was updated successfully, but these errors were encountered:
This issue has been automatically locked due to no recent activity. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.
vercel
locked as resolved and limited conversation to collaborators
Jan 28, 2022
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
What version of Next.js are you using?
11.0.1
What version of Node.js are you using?
14.16.0
What browser are you using?
Chrome version 91.0.4472.114 (Official Build) (64-bit)
What operating system are you using?
Windows 10 Home (64-bit)
How are you deploying your application?
next dev/next build
Describe the Bug
When running
next build
ornext start
the configurednext-env.d.ts
gets overwritten and all configurations are removed. I'm using the next-page-transitions package to add transition effects on navigation but when I import the package typescript yells that no type definitions found for packagenext-page-transitions
.To solve this I added custom type declarations for the
next-page-transitions
and.svg
files, by doing so mynext-env.d.ts
files looks like this.But when I run
next build
ornext dev
commands it overwrites mynext-env.d.ts
file to thisBTW I'm using the yarn package manager and using the
yarn run dev
andyarn run build
commands. Due to this bug, I have to rewrite the file every time I need to start the server.Expected Behavior
Should not overwrite the type declaration file.
To Reproduce
Just initialize a new Next.js project with
yarn create next-app --typescript
and add type declarations for packages innext-env.d.ts
file or follow up using this repositoryThe text was updated successfully, but these errors were encountered: