piniaの組み込みメソッド$resetは、storeがオブジェクト構文で作られていれば使えるが、Function構文の場合はPiniaのプラグインを作成する必要がある。

reponrepon のブックマーク 2022/09/15 10:51

その他

このブックマークにはスターがありません。
最初のスターをつけてみよう!

Pinia: How to reset stores created with function/setup syntax

    Pinia shares a lot of similarities with Vuex but it's simpler, type safe and extensible! If you haven't tried it yet, checkout the docs to get started! Object and Function stores There are two ways...

    \ コメントが サクサク読める アプリです /

    • App Storeからダウンロード
    • Google Playで手に入れよう