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

fix(frontend): 修复生成API文件framework判断异常的问题 #166

Closed
wants to merge 5 commits into from
Closed

fix(frontend): 修复生成API文件framework判断异常的问题 #166

wants to merge 5 commits into from

Conversation

Nakus0426
Copy link

No description provided.

@uyarn
Copy link
Contributor

uyarn commented Jul 12, 2023

之前是 npm run api:docs component 'framework(PC)'

@Nakus0426
Copy link
Author

是的,之前生成的命令是 'framework' ,执行命令时解析出来时变成了 ''framework'',导致校验一直通不过

@uyarn
Copy link
Contributor

uyarn commented Jul 13, 2023

是的,之前生成的命令是 'framework' ,执行命令时解析出来时变成了 ''framework'',导致校验一直通不过

咦 我这边执行好像没有遇到这个问题喔?

@uyarn
Copy link
Contributor

uyarn commented Jul 13, 2023

是指 npm run api:docs component 'framework(PC)' 这样执行 会不通过?

@liweijie0812
Copy link
Member

改错地方了,改这里复制命令到终端执行报错的, ()是特殊符号来的,需要'' 包裹

@Nakus0426
Copy link
Author

Nakus0426 commented Jul 14, 2023

把生成API文件弹窗生成的命令复制到终端执行是可以执行的,但点击生成按钮执行则会报错。
因为 packages/scripts/index.js 中的 const [component, framework, allParams] = process.argv.slice(2) 这行代码结构出来的变量 framework 会变成下面这样:const framework = "'framework(PC)'"

这里我确实忽略了用户会把生成的命令复制到终端执行的可能性,我待会再修改一下

@chaishi
Copy link
Contributor

chaishi commented Jul 16, 2023

当前存在很多非必要变更,仅提供 framework 判断相关的变更更合适,辛苦调整一下。
调整后,我们在重新 CR 🌹

@Nakus0426
Copy link
Author

当前存在很多非必要变更,仅提供 framework 判断相关的变更更合适,辛苦调整一下。 调整后,我们在重新 CR 🌹

这些多余的变更是rebase后产生的,应该没关系吧

@Nakus0426 Nakus0426 closed this Aug 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants