Add commit hook - #65
Merged
Merged
Conversation
RikSchefferAmsterdam
requested review from
a team
and
a lite review from Copilot
September 9, 2026 07:02
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
It introduces a breaking Node ESM/CJS change and the hook/config setup is currently incomplete/incorrect, so the intended commit hook behavior will not work reliably.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
This PR aims to introduce a commit-time formatting workflow by adding Husky and lint-staged to the repository’s Node toolchain.
Changes:
- Added
huskyandlint-stagedas dev dependencies and added apreparescript to initialize Husky. - Added a lint-staged configuration file (
.lintstagedrc.js) intended to runoxfmton staged files. - Updated
package-lock.jsonto include the new dependencies.
File summaries
| File | Description |
|---|---|
| package.json | Adds Husky/lint-staged tooling, Husky prepare script, and sets package type to module. |
| package-lock.json | Locks Husky/lint-staged and their transitive dependencies. |
| .lintstagedrc.js | Introduces lint-staged rules intended to run oxfmt on staged files. |
Review details
- Files reviewed: 2/3 changed files
- Comments generated: 3
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
26
to
30
| "volta": { | ||
| "node": "24.19.0" | ||
| } | ||
| }, | ||
| "type": "module" | ||
| } |
Comment on lines
+1
to
+3
| export default { | ||
| '!(*package-lock).(js|jsx|ts|tsx|json|md|yml|yaml|css)': 'npx oxfmt', | ||
| } |
Comment on lines
+18
to
+23
| "format:fix": "oxfmt", | ||
| "prepare": "husky" | ||
| }, | ||
| "devDependencies": { | ||
| "husky": "^9.1.6", | ||
| "lint-staged": "^17.0.4", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
Test instructions
Other notes