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

feat: add oxlint linting system for frontend code to githook and add github action #34

Merged
merged 2 commits into from
Dec 15, 2023

Conversation

PThorpe92
Copy link
Member

Currently we have Prettier running as a formatter but as the front end code grows, we will need something like eslint which is well known for being slow and not written in Rust. So the clear option is oxlint which is neither

@nokierae
Copy link
Collaborator

This PR has oxlint run In the pre-commit hook, but I don't see it added as a dev dependency in the package.json file. It also looks like you've kept prettier as a dependency and the prettier ignore file. Do we still need those?

Otherwise looks great!

@PThorpe92
Copy link
Member Author

PThorpe92 commented Dec 15, 2023

Good catch! This does need to be added as a dependency to the package.json file,

It sounds unclear in my comment, but this is added in place of something like eslint for semantic and syntactic errors, and actually doesn't provide formatting like prettier, so we will be continuing to use prettier for formatting.

I removed the npx prettier -w . from the .husky pre-commit file because I noticed it is running in the background as part of "lint-staged" (so we had it running twice)

@nokierae nokierae merged commit 1f2fbb8 into UnlockedLabs:main Dec 15, 2023
5 checks passed
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.

2 participants