-
-
Notifications
You must be signed in to change notification settings - Fork 6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(create-app): improve client types #3214
Conversation
Anyone would like to review this PR? cc @Shinigami92 😉 |
I'm not so sure about this PR 🤔 On the one side, if someone really needs it, they could easily just add types to the e.g. for tests, I personally have an extra Are there more benefits of doing this? Do we have some real world examples? |
@Shinigami92 I'd say setting Next.js also uses this approach, creating a Cypress is an exception since the Cypress & Jest globals interfere with each other, and like you said, that is normally a separate tsconfig in any case. In general you shouldn't have to make a config change for each package you add [that affects the global types]. |
Yes, remove |
Okay, so what about naming the file Also we could add a documentation section for explaining this file, like in the Next.js docs. |
Have tested it and yes it's working, please rename the file and then we can merge it |
Also updated the doc of |
Description
Definition of tsconfig.types on the TS documentation writes
So if use Vite to create a *-ts project and TS will not recognize global definition such as Jest unless add Jest to tsconfig.types.
Additional context
What is the purpose of this pull request?
Before submitting the PR, please make sure you do the following
fixes #123
).