-
Notifications
You must be signed in to change notification settings - Fork 1
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
package.jsonの加筆 #27
package.jsonの加筆 #27
Conversation
.eslintrc.js
Outdated
@@ -18,6 +18,7 @@ module.exports = { | |||
'vue/eqeqeq': 'error', | |||
'@typescript-eslint/consistent-type-imports': 'error', | |||
'vue/require-default-prop': 'off', | |||
'@typescript-eslint/no-explicit-any': 'off', |
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.
これを書くと、手で書いたファイルを含めてすべてのファイルにおいてany型を許容してしまうことになりそうです。
src/apis/openAPI.ts のみでany型を許容しないようにするために、.eslintignore にsrc/apis/openAPI.tsを含めるのがよさそう
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.
src/apis/openAPI.tsで永久にany
型が自動生成され続けるので、openAPI.tsのみでany型を許容するほうがパット見良さそう…?
ただ、oneOfが他のところでも使われている以上、他のファイルでもany型はそこそこ出てきそうな気はします
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のoverridesフィールドを使うと良さそうです
https://blog.popweb.dev/programming/javascript/eslint-overrides/
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.
細かいですが確認お願いします:pray:
src/apis/client.ts
Outdated
|
||
// global configuration | ||
fetcher.configure({ | ||
baseUrl: '', //どのURLを参照するかわからなかったので空にした |
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.
環境変数から読み込むのが良さそう
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.
細々としたところで申し訳ないんですが修正お願いします!🙇
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.
良さそうです~ 何度も修正提案しちゃってごめんなさい!お疲れさまでした!
openapi-typescript導入+package.jsonに記載
ただ生成した.tsから型を自動的に決めるコードの実装の仕方が一向にわからない