Skip to content
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

Make lex-gen type more precise #2956

Draft
wants to merge 6 commits into
base: main
Choose a base branch
from
Draft

Conversation

matthieusieben
Copy link
Contributor

@matthieusieben matthieusieben commented Nov 7, 2024

Fixes #2952

While reviewing, "codegen" commits can be ignored ;-)

@matthieusieben matthieusieben force-pushed the msi/lex-gen-typefixes branch 4 times, most recently from f22ff9f to 005584a Compare November 8, 2024 20:40
@matthieusieben matthieusieben marked this pull request as draft November 8, 2024 20:40
@matthieusieben matthieusieben force-pushed the msi/lex-gen-typefixes branch 4 times, most recently from 71b5042 to 8b364ce Compare November 12, 2024 14:26
@matthieusieben matthieusieben force-pushed the msi/lex-gen-typefixes branch 2 times, most recently from f5707e0 to 3e52922 Compare November 12, 2024 15:40
Comment on lines -64 to -72
declare global {
interface Array<T> {
findLast(
predicate: (value: T, index: number, obj: T[]) => unknown,
thisArg?: any,
): T
}
}

Copy link
Contributor Author

@matthieusieben matthieusieben Nov 12, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not the proper type def for this method. The correct signature is provided by ts's 2023 lib. We need the correct def for the updatePreferences methods to work.

Since we are relying on this method, I updated the tsconfig to use 2023 lib instead of 2022.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Generation of Omit in lex-cli types causes loss of type safety
1 participant