mistercrunch commented on code in PR #32261:
URL: https://github.com/apache/superset/pull/32261#discussion_r1956783597
##########
.pre-commit-config.yaml:
##########
@@ -68,6 +68,39 @@ repos:
language: system
pass_filenames: true
files: \.(js|jsx|ts|tsx)$
+ - repo: local
+ hooks:
+ - id: type-checking-frontend
+ name: Type-Checking (Frontend)
+ entry: ./scripts/check-type.js
Review Comment:
know that `npm run type` take 10-30 seconds, we don't want to add this kind
of lag for each commit, especially when you're not even touching these files.
Key here is to somehow pass the list of files touched in the commit
(provided by pre-commit), and only run the checks on those files. Now guessing
`tsc` may have to go and import all the related files referenced in that seed
file, and could end up taking quite some time if you end up covering
files-that-import-files-that-import-other-files, ...
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]