Skip to content

next dev rewrites tsconfig.json #8128

Closed
@borekb

Description

@borekb

Bug report

Describe the bug

When I run next dev and some of the "required" Next.js options are missing (even non-critical ones like forceConsistentCasingInFileNames), my tsconfig.json is completely rewritten – my comments are deleted and the file is re-formatted.

To Reproduce

  1. Start next dev
  2. In tsconfig.json, remove forceConsistentCasingInFileNames and add some comment.
  3. Start next dev again
  4. Observe that your comment is deleted

Expected behavior

My tsconfig.json is my tsconfig.json 😄.

System information

  • OS: macOS
  • Version of Next.js: 9.0.2

Additional context

This is from the "TypeScript support is too eager in v9" bucket, IMO. Some more issues I'd regard in that category are e.g. #7687 or #8065 (though they are about different things).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    good first issueEasy to fix issues, good for newcomers

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions