mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-30 11:11:53 +00:00
Run pre-commit type check only for TypeScript (#1597)
* Prevent unnecessary type-checks * Remove commented code
This commit is contained in:
13
lint-staged.config.js
Normal file
13
lint-staged.config.js
Normal file
@@ -0,0 +1,13 @@
|
||||
export default {
|
||||
'./**/*.js': (stagedFiles) => formatFiles(stagedFiles),
|
||||
|
||||
'./**/*.{ts,tsx,vue}': (stagedFiles) => [
|
||||
...formatFiles(stagedFiles),
|
||||
'tsc --noEmit',
|
||||
'tsc-strict'
|
||||
]
|
||||
}
|
||||
|
||||
function formatFiles(fileNames) {
|
||||
return [`prettier --write ${fileNames.join(' ')}`]
|
||||
}
|
||||
Reference in New Issue
Block a user