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

Use ESLint and PrettierJS #2726

Open
wants to merge 20 commits into
base: master
Choose a base branch
from

Conversation

4yman-0
Copy link

@4yman-0 4yman-0 commented Dec 12, 2024

closes #2724

TODO:

  • Add PrettierJS
  • Better configuration:
    • ESLint
    • Prettier
  • Fix undefined document and other browser APIs

- [ ] Better configuration.
- [ ] Undefined `document` and possibly other browser APIs.

Dr. ImprovedSpaghetti, TYSM for all the hassles and BS I had to dig through. You have taught me discipline and seriousness
by making me deal with the most ???? that nobody told anyone was to recommended way of doing thing.

THANK YOU!
@4yman-0 4yman-0 self-assigned this Dec 12, 2024
@4yman-0 4yman-0 changed the title Use ESLint and prettier Use ESLint and PrettierJS Dec 12, 2024
@4yman-0 4yman-0 marked this pull request as ready for review December 12, 2024 11:03
@4yman-0

This comment was marked as outdated.

@4yman-0

This comment was marked as off-topic.

@ImprovedTube
Copy link
Member

hi! @4yman-0 woaw +1,115 −930

i saw some version number go down too?
can we keep files in a sub-folder?

@4yman-0

This comment was marked as outdated.

@ImprovedTube
Copy link
Member

hi! previously @dodieboy customized this. And @raszpl. (And i tried adding CSS linting)

down






won't

why / which other subfolder fits better?

@4yman-0
Copy link
Author

4yman-0 commented Dec 13, 2024

hi! previously @dodieboy customized this. And @raszpl. (And i tried adding CSS linting)

I ran node update and some magic to add ESlint and PrettierJS. In ESLint's "flat" configuration file, I used the recommended options with very little customization. Prettier's config can be improved. As for CSSLint, it didn't work so I removed it.

why / which other subfolder fits better?

Why?

The tests folder shouldn't contain config files the same way images and css don't fit in one directory.

Which?

  • config

I don't know if all the tools will work with custom config paths.

Edit: typo

@4yman-0

This comment was marked as resolved.

@ImprovedTube
Copy link
Member

just not sure how much time the guys spent yet on customizing ESlinting rules /policy. #2446 #2438


(
Generally debugging can be enforced;
Better methods can be strongly suggested;
White-spaces suggestions can be friendly options only, since they only matter, if they are intentionally placed (When fully following beauty-standards, then one could also simply remove all white-space from all code and commits / PRs, while everybody could always chose their own local flavor /"IDE-theme", instead of actually keeping any white-space in any repo. Same would work with some intentionally different white-spaces present, but instead of them being the only ones removed, they would be, the only ones to stay and maybe color-marked up or so)

CSSLint, didn't work so I removed it.

i might tend to resign late (why not?)
)

@ImprovedTube
Copy link
Member

Jest breaks when I choose it with --config

yes 🤔 tests & config in one folder are intuitive for newbies and not a bad difference otherwise. Yet i just wanted to keep the root directory empty and the readme.md up, which isn't important enough /a lost cause😂

@dodieboy
Copy link
Member

Most of the lint config is based on @raszpl and the original format of this project to standardise how this project present our code. I'm ok with the config as long as @ImprovedTube is ok with it.

Prettier is a good tool too, I often use it with my vscode.

@ImprovedTube
Copy link
Member

i saw some version number go down too?

(all could say latest?)

@ImprovedTube
Copy link
Member

hi @dodieboy thank you! hope you are fine!

@dodieboy
Copy link
Member

i saw some version number go down too?

(all could say latest?)

Truly say, it is not recommended to used latest, as it will result in auto update and our config may break. @4yman-0 for changing on that part but any reason to downgrade eslint from v9 to V8?

@4yman-0
Copy link
Author

4yman-0 commented Dec 15, 2024

reason to downgrade eslint from v9 to V8?

None.

@ImprovedTube
Copy link
Member

hi @4yman-0
(...good point thinking of build.py too! not currently using it, but should (if not even better, through github actions; Currently building 4 different versions manually)
(as always, editing that felt a bit productive/meaningful, removing nothing but hoarding ("readme.md" "previews" "py"), so that the code could be repurposed. "Everything as a framework")

@4yman-0

This comment was marked as spam.

@4yman-0 4yman-0 force-pushed the prettier-eslint branch 2 times, most recently from 8fb7cd4 to 0e2980a Compare December 29, 2024 17:50
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.

Add ESLint and Prettier Rules Config Files
3 participants