Skip to content

[✨] Update your template to include eslint.config.js by default #6115

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

Closed
hosseinitabar opened this issue Apr 11, 2024 · 11 comments · Fixed by #7418
Closed

[✨] Update your template to include eslint.config.js by default #6115

hosseinitabar opened this issue Apr 11, 2024 · 11 comments · Fixed by #7418
Labels
STATUS-1: needs triage New issue which needs to be triaged TYPE: enhancement New feature or request

Comments

@hosseinitabar
Copy link

Is your feature request related to a problem?

Yes. I used npm create qwik and it created a project based on 1.5.2 version. Yet when I updated it to use eslint 9.0.0 and ran npm run build I got this error:

node:748) ESLintIgnoreWarning: The ".eslintignore" file is no longer supported. Switch to using the "ignores" property in "eslint.config.js"

Describe the solution you'd like

Please remove .eslintignore and .eslintconfig.cjs from your template and replace them with a single eslint.config.js.

Describe alternatives you've considered

Right now we should manually do this in every project.

Additional context

No response

@hosseinitabar hosseinitabar added STATUS-1: needs triage New issue which needs to be triaged TYPE: enhancement New feature or request labels Apr 11, 2024
@gioboa
Copy link
Member

gioboa commented Apr 11, 2024

Thanks @hosseinitabar
Would you like to create a PR for that?

@hosseinitabar
Copy link
Author

@gioboa, I'm sorry I don't know how to do that.

@JerryWu1234
Copy link
Contributor

let me try it

@JerryWu1234
Copy link
Contributor

JerryWu1234 commented Apr 29, 2024

Will this bug from v1 be merged into v2 when I finish this bug ?

@gioboa
Copy link
Member

gioboa commented Apr 29, 2024

Yep, it will be merged. Thanks for your help @JerryWu1234

@JerryWu1234
Copy link
Contributor

JerryWu1234 commented May 9, 2024

because the eslint 9.0 was a breaking change version, and I have used this library @eslint/eslintrc which the official have offered for migrate to v9.0,but it's still unstable , so we can wait a moment

eslint/eslintrc#158

@wmertens
Copy link
Member

wmertens commented May 9, 2024

I think we should use the ts one that helps with the types https://typescript-eslint.io/getting-started/

@wmertens
Copy link
Member

wmertens commented May 9, 2024

BTW @JerryWu1234 you need to rename your file to .cjs or it won't work in type:module projects. And maybe you should make it ESM with .mjs, but then __dirname needs to be replaced with the equivalent import.meta statement

@JerryWu1234
Copy link
Contributor

I think we should use the ts one that helps with the types https://typescript-eslint.io/getting-started/

we just upgrade the Eslint's grade. and follow this doc don't you?,
So why we have to refer a new library?

BTW @JerryWu1234 you need to rename your file to .cjs or it won't work in type:module projects. And maybe you should make it ESM with .mjs, but then __dirname needs to be replaced with the equivalent import.meta statement

I tried both ways, it's still wrong.

@JerryWu1234
Copy link
Contributor

JerryWu1234 commented May 9, 2024

typescript-eslint/typescript-eslint#8211

still going on for ESLint v9 Support

@PatrickJS
Copy link
Member

yup it would be awesome to convert those two files into one

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
STATUS-1: needs triage New issue which needs to be triaged TYPE: enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants