-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
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
[WIP] Migrate jest-repl to typescript #8000
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just some things I could use some help with
*/ | ||
|
||
import Runtime from 'jest-runtime'; | ||
|
||
export const usage = 'Usage: $0 [--config=<pathToConfigFile>]'; | ||
|
||
export const options = { | ||
...Runtime.getCLIOptions(), | ||
export const options = Object.assign({}, Runtime.getCLIOptions(), { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doing this gets a better type.
packages/jest-repl/src/cli/index.ts
Outdated
const argv = yargs.usage(args.usage).options(args.options).argv; | ||
|
||
validateCLIOptions(argv, {...args.options, deprecationEntries}); | ||
|
||
argv._ = [REPL_SCRIPT]; | ||
|
||
//@ts-ignore Get feedback first in PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The compiler complains that argv has some keys missing. Not sure how to resolve this at the moment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, the argv typing is not really where it should be. this is fine for now 🙂
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great 😀 Could you update the changelog?
Sure thing about the changelog. Was just opening the PR early to get the ball rolling. |
Hmm I think I introduced a regression. All the tests are failing with the same error. hmm 😞 |
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
This PR migrates jest-repl to typescript.
Notes: