Skip to content

Commit 90a8be6

Browse files
committed
🌮 docs: add docs/other/development-tips
1 parent 59aa190 commit 90a8be6

File tree

2 files changed

+16
-3
lines changed

2 files changed

+16
-3
lines changed

docs/_sidebar.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,11 @@
6363

6464
- ツール
6565

66-
- [オススメライブラリ一覧]()
66+
- [オススメライブラリ一覧](tools/recommend-tools.md)
6767

6868
- その他
6969

70-
- [気をつけるポイント]()
71-
- [ログイン処理をどう実装するか]()
70+
- [開発で気をつけるポイント](other/development-tips.md)
71+
- [Nuxt.jsを使ったログイン周りの仕組みについて]()
7272
- [サーバーサイドのログ処理](nuxt/server-side-logging.md)
7373
- [Google Tag Manager]()

docs/other/development-tips.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
## 開発で気をつけるポイント
2+
3+
- Nuxt の `plugin` を使わずに `prototype` 拡張をどこかのファイルでやるのはやめましょう
4+
- Cookie は使わず、なるべく localStorage を使いましょう
5+
- [Nuxt.jsでログインをどうやるか、そしてCookieからlocalStorageへ - DJ lemon-Sour's diary (prod.hisasann)](https://hisasann.github.io/2019/06/22/how-to-login-with-nuxt-and-cookie-to-localstorage/)
6+
- document オブジェクト系はなるべく使わないようにしましょう
7+
document.getElementById(id)など
8+
- `alert``confirm``process.client` の場合に使うように if 文で判定しましょう
9+
- `v-bind:val` ではなく、エイリアスを使いましょう `:val`
10+
- `v-on:event` ではなく、エイリアスを使いましょう `@event`
11+
- コールバックパターンよりも `async/await パターン` を使いましょう
12+
- input 系のバリデーションは `vee-validattor` を使いましょう
13+
[vee-validateを使う - typescript-nuxtjs-boilerplate-docs](https://typescript-nuxtjs-boilerplate-docs.netlify.com/#/nuxt/vee-validate)

0 commit comments

Comments
 (0)