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 eslint preset #20

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

qiushui7
Copy link
Member

No description provided.

@vercel
Copy link

vercel bot commented Jun 26, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
doctor ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 26, 2023 4:43am

@@ -0,0 +1,34 @@
{
"name": "@doctors/eslint",
"version": "0.0.3",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

版本可以同步一下其他包

"license": "MIT",
"files": [
"./dist",
"./bin"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

除了 @doctors/core 之外不需要 bin 字段 可以删除一下

* @return {*}
* @param api
*/
export function getConfigFile(api: IApi) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个函数可以单独放一个文件

// getEslintConfigFile.ts
export default  getEslntConfigFile(){}

api.addDoctorEslintCheck((meta) => {
const { eslintConfig } = meta;
let isEsLintOk: boolean = true;
const prerequisites = ["env", "extends", "parserOptions", "rules"];
Copy link
Member

@BoyYangzai BoyYangzai Jun 26, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

对于 esolint 预设来说 这四个缺一不可吗?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

应该有哪些必备预设呢

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants