こちらで実現できました 参考記事 Trigger
カテゴリーアーカイブ: TypeScript
Please reinstall Cypress by running: cypress install
cypressを起動しようとしたところタイトルのエラーが発生しました yarnでcypressを強制installすることで対応しました🙌 参考記事 Cypress failed to start on …
“Please reinstall Cypress by running: cypress install” の続きを読む
TypeScriptで`TS1192: Module ‘”./node_modules/@types/react/index”‘ has no default export.
RailsにReact + TypeScript入れたタイトルのエラー発生 こちらで治りました🙏 参考記事 TypeScriptでTS1192: Module ‘”./node_modules/@type …
“TypeScriptで`TS1192: Module ‘”./node_modules/@types/react/index”‘ has no default export.” の続きを読む
axiosで401のinterceptorを実装
401返ってきたときに自動的にtoken取得するためのコードを実装しました 参考記事 Using Axios interceptors for refreshing your API token.
Next.jsでscriptが読み込まれない時の解消方
Twitter widgetやHubspotのscriptをheaderに入れたけど、動かない!という場合は、適宜下記のように実装することで問題を解消することができます🙏 参考記事 Next.js アプリ …
Next.jsでdevelopmentかどうか?を判断する方法
Next.jsのSSGを開発環境では制限したく、envでの制御を行いました こちらの関数を利用することで、開発環境かどうかの分岐を利用することができます nodeなので、nestjsやexpressと同様ですǶ …
TS2339: Property ‘id’ does not exist on type ‘T’.
T にidを付け加える方法で、 複数の型で同じ関数を使う際に抽象化して作成したい時が結構あるかと思います。 こちらで参考にしたらいけました 参考記事 Property ‘id’ does not …
react-selectで10000件のlist表示する
下記のコードを参考に実装しました
axios.createのテスト
参考記事をベースに作成しました 参考記事 Jestでデフォルト値設定済みのaxiosインスタンスに対するMockテスト
React test
これめっちゃいいかも!!!!https://qiita.com/Hitomi_Nagano/items/df30da9086b705532aca http://5.9.10.113/67035315/how-to-tes …