-
Notifications
You must be signed in to change notification settings - Fork 28
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: check header and ci lint #88
Conversation
@Debbl is attempting to deploy a commit to the OpenBuild Team on Vercel. A member of the Team first needs to authorize it. |
"headers/header-format": [ | ||
"error", | ||
{ | ||
"source": "string", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
使用文件的方式,把 license.js
文件中的那部分弄到单独的文件里,也读取文件拿,保证两个地方是同一个数据源。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
其实我推荐完全使用 ESLint 来做添加 license,在 lint-stage 执行 lint 就可以自动格式化
如果要保留 license.js 并且统一与 ESLint 的内容,目前的配置文件好像无法做到,可以考虑升级到 ESLint v9 #89 并使用 eslint.config.js
配置文件
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
需要加 header 的还有 CSS/SCSS 文件
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ESLint 默认好像不支持格式化 CSS 文件,这个插件好像也不支持,是否考虑可以把这个项目变成一个 monorepo 的项目,我可以自己写一个类似功能的插件
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
现在不考虑 monorepo。npm run license
已经支持给 CSS、SCSS 文件加头。
@Debbl 那是 |
fix #66