-
-
Notifications
You must be signed in to change notification settings - Fork 720
Labels
A-linterArea - LinterArea - Linter
Description
What version of Oxlint are you using?
1.28.0
What command did you run?
oxlint src/bad.tsx
What does your .oxlintrc.json config file look like?
What happened?
eslint-plugin-solid fails because context.getSourceCode() is defined but just throws. The eslint implementation of the function returns the sourcecode even though it's depreciated. I think the 2 options are stop defining getSourceCode, or implement the function.
If i patch getSourceCode to return context.sourceCode then the rules work as expected
export function getSourceCode(context: CompatContext) {
if (typeof context.getSourceCode === "function") {
return context.getSourceCode();
}
return context.sourceCode;
}
``
Metadata
Metadata
Assignees
Labels
A-linterArea - LinterArea - Linter
{ "jsPlugins": [ "eslint-plugin-solid" ], "rules": { // identifier usage is important "solid/jsx-no-duplicate-props": 2, // "solid/jsx-uses-vars": 2, // not supported by oxc yet (uses markVariableAsUsed) // security problems "solid/no-innerhtml": 2, "solid/jsx-no-script-url": 2, // reactivity "solid/components-return-once": 1, "solid/no-destructure": 2, "solid/prefer-for": 2, "solid/reactivity": 1, // affected by this bug "solid/event-handlers": 1, // affected by this bug // these rules are mostly style suggestions "solid/imports": 1, "solid/style-prop": 1, "solid/no-react-deps": 1, "solid/no-react-specific-props": 1, "solid/self-closing-comp": 1, "solid/no-array-handlers": 2, "solid/prefer-show": 1 // affected by this bug }, }