2024/09/21 ~ 2024/09/27 のもくもく日記
もくもく 前回までは
2024/09/14 ~ 2024/09/20 のもくもく日記 をご覧ください。
途中経過
その1
Google Workspace に所属していない個人アカウントだと、 OAuth 同意画面のUser Type は「外部」しか選べず、設定がややこしいorz
とりあえずドキュメントのサンプルコード を実行できた!
その2
Angular のReactive Form のインスタンス管理をミスって、
FormArray
の追加・削除などが上手くいかないorz
……Component を切ったりしなければ動いていたので、ベタ書きに戻すか 🤔
……Angular でFormArray
の要素を追加・削除した時の<input>
のvalue が変だなと思ったら、
@for
のtrack にindex を指定していて、index 自体は変化が無いから再描画されていないだけだったw
FormArray
のcontrols を*ngFor
から @for
に書き換えたのだけど、track すべきものが分からなすぎてNG0956 が永遠と出続けるorz
下記で紹介されているマイグレーションコマンドを使っても改善しなかったので、自分の組み方が悪い気がするけど、さてどうしよう 🤔
その3
React でJSON Schema に沿った編集欄を作ってくれるこのライブラリを試したのだけど、 anyOf の解釈が上手く行っていないようにみえるので、自分が仕様をミスっている気がしてきたorz
https://rjsf-team.github.io/react-jsonschema-form/
その4
GitHub Pages にAngular で作ったサイトをデプロイしたら何も表示されなくて困ったけど、
下記リンクを参考に<base href="???">
の設定を調整したら、表示できるようになった!
https://dev.to/danielcaballero88/how-to-deploy-angular-website-to-github-pages-jhb
その5
ざっくりとTypeSpec ファイルを独自加工して、それに対応した入力欄をつくるサンプルが出来た 🎉
……ちゃんとした動作確認とかも必要だけど、それはこの仕組みを導入した時にやってこっとw
https://github.com/tshion/TryTypeSpecEditor
その6
テンプレートエンジン、 Python だとJinja があるけど、 それをNode.js で実装する場合は、インスパイアされたnunjucks というのがあるっぽい 👀
Mozilla が作っているので、使ってみても良いかもしれないw
https://mozilla.github.io/nunjucks/
今回の進捗
- GitHub
- Nintendo Switch でトレーニングを進めた
- 本を読み進めた
※関連SNS
- https://x.com/shion_engineer/status/1837337412839866625
- https://x.com/shion_engineer/status/1837365819845792162
- https://x.com/shion_engineer/status/1837402239847354834
- https://x.com/shion_engineer/status/1837834130916364770
- https://x.com/shion_engineer/status/1837847401136378094
- https://x.com/shion_engineer/status/1837876383911207149
- https://x.com/shion_engineer/status/1838123166985810150
- https://x.com/shion_engineer/status/1838124239481938253
- https://x.com/shion_engineer/status/1838150794300071944
- https://x.com/shion_engineer/status/1838925367953727500
- https://x.com/shion_engineer/status/1839192687549001802