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

autocorrect: false doesn't work #179

Open
chunyulo-code opened this issue Dec 19, 2023 · 1 comment
Open

autocorrect: false doesn't work #179

chunyulo-code opened this issue Dec 19, 2023 · 1 comment

Comments

@chunyulo-code
Copy link

chunyulo-code commented Dec 19, 2023

When hit save, the symbol becomes , symbol, and this line autocorrect: false doesn't work. Did I miss something?

//before
// autocorrect: false
render: productCourses => productCourses.map(courseCode => courses.nameMap[courseCode]).join('、'),
// autocorrect: true
//after
// autocorrect: false
render: productCourses => productCourses.map(courseCode => courses.nameMap[courseCode]).join(','),
// autocorrect: true

AutoCorrectVersion:v2.6.4

@huacnlee
Copy link
Owner

huacnlee commented May 7, 2024

I have do a test.

Make a test.js:

//before
// autocorrect: false
render: productCourses => productCourses.map(courseCode => courses.nameMap[courseCode]).join('、'),
// autocorrect: true

And then run autocorrect --lint test.js there is no output.

Please tell me your filename.

AutoCorrect is used the extension name to match for format type. The ignoror syntax is following the comment syntax of the format type.

So if your file not a .js or .ts, for example a .md or .txt, then AutoCorrect will regard it as a Markdown or PlainText, so the // is not a comment syntax in Markdown or PlainText, so the autocorrect: false will not work.

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

No branches or pull requests

2 participants