[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"module-pinia":3,"versions":670},{"name":4,"description":5,"repo":6,"npm":7,"icon":8,"github":9,"website":10,"learn_more":11,"category":12,"type":13,"maintainers":14,"compatibility":19,"generatedAt":23,"contributors":24,"stats":112,"readme":121},"pinia","The Vue Store that you will enjoy using","vuejs/pinia#v2/packages/nuxt","@pinia/nuxt","pinia.svg","https://github.com/vuejs/pinia","https://pinia.vuejs.org/","","Extensions","3rd-party",[15],{"name":16,"github":17,"twitter":17,"bluesky":18},"Eduardo San Martin Morote","posva","esm.dev",{"nuxt":20,"requires":21},"^3.15.0 || ^4.0.0",{"bridge":22},"optional","2026-05-04T12:56:08.597Z",[25,28,32,36,40,44,47,51,55,59,62,65,68,71,75,78,81,84,87,90,93,97,100,103,106,109],{"id":26,"username":17,"contributions":27},664177,1516,{"id":29,"username":30,"contributions":31},5158436,"pi0",18,{"id":33,"username":34,"contributions":35},3766839,"nicodevs",14,{"id":37,"username":38,"contributions":39},28706372,"danielroe",13,{"id":41,"username":42,"contributions":43},44336070,"idorenyinudoh",7,{"id":45,"username":46,"contributions":43},65301168,"skirtles-code",{"id":48,"username":49,"contributions":50},57580045,"wangenze267",6,{"id":52,"username":53,"contributions":54},29396513,"Akhigbe-E",5,{"id":56,"username":57,"contributions":58},4183726,"antony-k1208",4,{"id":60,"username":61,"contributions":58},7635209,"danielkellyio",{"id":63,"username":64,"contributions":58},30027636,"i5dr0id",{"id":66,"username":67,"contributions":58},46400789,"JeraldVin",{"id":69,"username":70,"contributions":58},26253657,"niceplugin",{"id":72,"username":73,"contributions":74},24556921,"jeremygoccc",3,{"id":76,"username":77,"contributions":74},10359255,"lazzzis",{"id":79,"username":80,"contributions":74},41575890,"taist24",{"id":82,"username":83,"contributions":74},52022476,"jh-leong",{"id":85,"username":86,"contributions":74},97254921,"tannazma",{"id":88,"username":89,"contributions":74},31008635,"nazarepiedady",{"id":91,"username":92,"contributions":74},1223583,"bodograumann",{"id":94,"username":95,"contributions":96},39984251,"Mini-ghost",2,{"id":98,"username":99,"contributions":96},40666434,"WalkAlone0325",{"id":101,"username":102,"contributions":96},74694190,"noootwo",{"id":104,"username":105,"contributions":96},31730646,"BlackCrowxyz",{"id":107,"username":108,"contributions":96},22591269,"tkint",{"id":110,"username":111,"contributions":96},360,"tslocke",{"version":113,"downloads":114,"stars":115,"watchers":116,"forks":117,"defaultBranch":118,"publishedAt":119,"createdAt":120},"0.11.3",2800371,14573,67,1183,"v4",1762334718224,1629381795526,{"data":122,"body":123,"toc":664},{"title":7,"description":11},{"type":124,"children":125},"root",[126,139,149,156,169,212,218,223,253,273,368,374,387,408,426,640,646,658],{"type":127,"tag":128,"props":129,"children":131},"element","h1",{"id":130},"pinianuxt",[132],{"type":127,"tag":133,"props":134,"children":136},"code",{"className":135},[],[137],{"type":138,"value":7},"text",{"type":127,"tag":140,"props":141,"children":142},"blockquote",{},[143],{"type":127,"tag":144,"props":145,"children":146},"p",{},[147],{"type":138,"value":148},"Nuxt module for Pinia",{"type":127,"tag":150,"props":151,"children":153},"h2",{"id":152},"automatic-installation",[154],{"type":138,"value":155},"Automatic Installation",{"type":127,"tag":144,"props":157,"children":158},{},[159,161,167],{"type":138,"value":160},"Use ",{"type":127,"tag":133,"props":162,"children":164},{"className":163},[],[165],{"type":138,"value":166},"nuxi",{"type":138,"value":168}," to automatically add this module to your Nuxt project:",{"type":127,"tag":170,"props":171,"children":175},"pre",{"className":172,"code":173,"language":174,"meta":11,"style":11},"language-shell shiki shiki-themes material-theme-lighter material-theme-lighter material-theme-palenight","npx nuxi@latest module add pinia\n","shell",[176],{"type":127,"tag":133,"props":177,"children":178},{"__ignoreMap":11},[179],{"type":127,"tag":180,"props":181,"children":184},"span",{"class":182,"line":183},"line",1,[185,191,197,202,207],{"type":127,"tag":180,"props":186,"children":188},{"style":187},"--shiki-light:#E2931D;--shiki-default:#E2931D;--shiki-dark:#FFCB6B",[189],{"type":138,"value":190},"npx",{"type":127,"tag":180,"props":192,"children":194},{"style":193},"--shiki-light:#91B859;--shiki-default:#91B859;--shiki-dark:#C3E88D",[195],{"type":138,"value":196}," nuxi@latest",{"type":127,"tag":180,"props":198,"children":199},{"style":193},[200],{"type":138,"value":201}," module",{"type":127,"tag":180,"props":203,"children":204},{"style":193},[205],{"type":138,"value":206}," add",{"type":127,"tag":180,"props":208,"children":209},{"style":193},[210],{"type":138,"value":211}," pinia\n",{"type":127,"tag":150,"props":213,"children":215},{"id":214},"manual-installation",[216],{"type":138,"value":217},"Manual Installation",{"type":127,"tag":144,"props":219,"children":220},{},[221],{"type":138,"value":222},"Add dependencies to your Nuxt project:",{"type":127,"tag":170,"props":224,"children":226},{"className":172,"code":225,"language":174,"meta":11,"style":11},"npm i pinia @pinia/nuxt\n",[227],{"type":127,"tag":133,"props":228,"children":229},{"__ignoreMap":11},[230],{"type":127,"tag":180,"props":231,"children":232},{"class":182,"line":183},[233,238,243,248],{"type":127,"tag":180,"props":234,"children":235},{"style":187},[236],{"type":138,"value":237},"npm",{"type":127,"tag":180,"props":239,"children":240},{"style":193},[241],{"type":138,"value":242}," i",{"type":127,"tag":180,"props":244,"children":245},{"style":193},[246],{"type":138,"value":247}," pinia",{"type":127,"tag":180,"props":249,"children":250},{"style":193},[251],{"type":138,"value":252}," @pinia/nuxt\n",{"type":127,"tag":144,"props":254,"children":255},{},[256,258,263,265,271],{"type":138,"value":257},"Enable the ",{"type":127,"tag":133,"props":259,"children":261},{"className":260},[],[262],{"type":138,"value":7},{"type":138,"value":264}," module in ",{"type":127,"tag":133,"props":266,"children":268},{"className":267},[],[269],{"type":138,"value":270},"nuxt.config.ts",{"type":138,"value":272},":",{"type":127,"tag":170,"props":274,"children":278},{"className":275,"code":276,"language":277,"meta":11,"style":11},"language-js shiki shiki-themes material-theme-lighter material-theme-lighter material-theme-palenight","export default defineNuxtConfig({\n    modules: ['@pinia/nuxt'],\n})\n","js",[279],{"type":127,"tag":133,"props":280,"children":281},{"__ignoreMap":11},[282,314,355],{"type":127,"tag":180,"props":283,"children":284},{"class":182,"line":183},[285,291,296,302,308],{"type":127,"tag":180,"props":286,"children":288},{"style":287},"--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#39ADB5;--shiki-default-font-style:italic;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic",[289],{"type":138,"value":290},"export",{"type":127,"tag":180,"props":292,"children":293},{"style":287},[294],{"type":138,"value":295}," default",{"type":127,"tag":180,"props":297,"children":299},{"style":298},"--shiki-light:#6182B8;--shiki-default:#6182B8;--shiki-dark:#82AAFF",[300],{"type":138,"value":301}," defineNuxtConfig",{"type":127,"tag":180,"props":303,"children":305},{"style":304},"--shiki-light:#90A4AE;--shiki-default:#90A4AE;--shiki-dark:#BABED8",[306],{"type":138,"value":307},"(",{"type":127,"tag":180,"props":309,"children":311},{"style":310},"--shiki-light:#39ADB5;--shiki-default:#39ADB5;--shiki-dark:#89DDFF",[312],{"type":138,"value":313},"{\n",{"type":127,"tag":180,"props":315,"children":316},{"class":182,"line":96},[317,323,327,332,337,341,345,350],{"type":127,"tag":180,"props":318,"children":320},{"style":319},"--shiki-light:#E53935;--shiki-default:#E53935;--shiki-dark:#F07178",[321],{"type":138,"value":322},"    modules",{"type":127,"tag":180,"props":324,"children":325},{"style":310},[326],{"type":138,"value":272},{"type":127,"tag":180,"props":328,"children":329},{"style":304},[330],{"type":138,"value":331}," [",{"type":127,"tag":180,"props":333,"children":334},{"style":310},[335],{"type":138,"value":336},"'",{"type":127,"tag":180,"props":338,"children":339},{"style":193},[340],{"type":138,"value":7},{"type":127,"tag":180,"props":342,"children":343},{"style":310},[344],{"type":138,"value":336},{"type":127,"tag":180,"props":346,"children":347},{"style":304},[348],{"type":138,"value":349},"]",{"type":127,"tag":180,"props":351,"children":352},{"style":310},[353],{"type":138,"value":354},",\n",{"type":127,"tag":180,"props":356,"children":357},{"class":182,"line":74},[358,363],{"type":127,"tag":180,"props":359,"children":360},{"style":310},[361],{"type":138,"value":362},"}",{"type":127,"tag":180,"props":364,"children":365},{"style":304},[366],{"type":138,"value":367},")\n",{"type":127,"tag":150,"props":369,"children":371},{"id":370},"configuring-the-module",[372],{"type":138,"value":373},"Configuring the Module",{"type":127,"tag":144,"props":375,"children":376},{},[377,379,385],{"type":138,"value":378},"By default, this module adds ",{"type":127,"tag":133,"props":380,"children":382},{"className":381},[],[383],{"type":138,"value":384},"stores",{"type":138,"value":386}," folder to auto imports, in which you can organize code related to Pinia stores in one place.",{"type":127,"tag":140,"props":388,"children":389},{},[390],{"type":127,"tag":144,"props":391,"children":392},{},[393,398,400,406],{"type":127,"tag":180,"props":394,"children":395},{},[396],{"type":138,"value":397},"!TIP",{"type":138,"value":399},"\nIn the new directory structure introduced since Nuxt 4, this directory is ",{"type":127,"tag":133,"props":401,"children":403},{"className":402},[],[404],{"type":138,"value":405},"app/stores",{"type":138,"value":407},".",{"type":127,"tag":144,"props":409,"children":410},{},[411,413,418,420,425],{"type":138,"value":412},"You can customize this behaviour using the ",{"type":127,"tag":133,"props":414,"children":416},{"className":415},[],[417],{"type":138,"value":4},{"type":138,"value":419}," property in ",{"type":127,"tag":133,"props":421,"children":423},{"className":422},[],[424],{"type":138,"value":270},{"type":138,"value":272},{"type":127,"tag":170,"props":427,"children":429},{"className":275,"code":428,"language":277,"meta":11,"style":11},"export default defineNuxtConfig({\n    modules: ['@pinia/nuxt'],\n    // configure the module using `pinia` property\n    pinia: {\n      /**\n       * Automatically add stores dirs to the auto imports. This is the same as\n       * directly adding the dirs to the `imports.dirs` option. If you want to\n       * also import nested stores, you can use the glob pattern `./stores/**`\n       * (on Nuxt 3) or `app/stores/**` (on Nuxt 4+)\n       *\n       * @default `['stores']`\n       */\n        storesDirs: []\n    }\n})\n",[430],{"type":127,"tag":133,"props":431,"children":432},{"__ignoreMap":11},[433,456,491,500,517,525,533,541,550,559,568,594,603,620,628],{"type":127,"tag":180,"props":434,"children":435},{"class":182,"line":183},[436,440,444,448,452],{"type":127,"tag":180,"props":437,"children":438},{"style":287},[439],{"type":138,"value":290},{"type":127,"tag":180,"props":441,"children":442},{"style":287},[443],{"type":138,"value":295},{"type":127,"tag":180,"props":445,"children":446},{"style":298},[447],{"type":138,"value":301},{"type":127,"tag":180,"props":449,"children":450},{"style":304},[451],{"type":138,"value":307},{"type":127,"tag":180,"props":453,"children":454},{"style":310},[455],{"type":138,"value":313},{"type":127,"tag":180,"props":457,"children":458},{"class":182,"line":96},[459,463,467,471,475,479,483,487],{"type":127,"tag":180,"props":460,"children":461},{"style":319},[462],{"type":138,"value":322},{"type":127,"tag":180,"props":464,"children":465},{"style":310},[466],{"type":138,"value":272},{"type":127,"tag":180,"props":468,"children":469},{"style":304},[470],{"type":138,"value":331},{"type":127,"tag":180,"props":472,"children":473},{"style":310},[474],{"type":138,"value":336},{"type":127,"tag":180,"props":476,"children":477},{"style":193},[478],{"type":138,"value":7},{"type":127,"tag":180,"props":480,"children":481},{"style":310},[482],{"type":138,"value":336},{"type":127,"tag":180,"props":484,"children":485},{"style":304},[486],{"type":138,"value":349},{"type":127,"tag":180,"props":488,"children":489},{"style":310},[490],{"type":138,"value":354},{"type":127,"tag":180,"props":492,"children":493},{"class":182,"line":74},[494],{"type":127,"tag":180,"props":495,"children":497},{"style":496},"--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#90A4AE;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic",[498],{"type":138,"value":499},"    // configure the module using `pinia` property\n",{"type":127,"tag":180,"props":501,"children":502},{"class":182,"line":58},[503,508,512],{"type":127,"tag":180,"props":504,"children":505},{"style":319},[506],{"type":138,"value":507},"    pinia",{"type":127,"tag":180,"props":509,"children":510},{"style":310},[511],{"type":138,"value":272},{"type":127,"tag":180,"props":513,"children":514},{"style":310},[515],{"type":138,"value":516}," {\n",{"type":127,"tag":180,"props":518,"children":519},{"class":182,"line":54},[520],{"type":127,"tag":180,"props":521,"children":522},{"style":496},[523],{"type":138,"value":524},"      /**\n",{"type":127,"tag":180,"props":526,"children":527},{"class":182,"line":50},[528],{"type":127,"tag":180,"props":529,"children":530},{"style":496},[531],{"type":138,"value":532},"       * Automatically add stores dirs to the auto imports. This is the same as\n",{"type":127,"tag":180,"props":534,"children":535},{"class":182,"line":43},[536],{"type":127,"tag":180,"props":537,"children":538},{"style":496},[539],{"type":138,"value":540},"       * directly adding the dirs to the `imports.dirs` option. If you want to\n",{"type":127,"tag":180,"props":542,"children":544},{"class":182,"line":543},8,[545],{"type":127,"tag":180,"props":546,"children":547},{"style":496},[548],{"type":138,"value":549},"       * also import nested stores, you can use the glob pattern `./stores/**`\n",{"type":127,"tag":180,"props":551,"children":553},{"class":182,"line":552},9,[554],{"type":127,"tag":180,"props":555,"children":556},{"style":496},[557],{"type":138,"value":558},"       * (on Nuxt 3) or `app/stores/**` (on Nuxt 4+)\n",{"type":127,"tag":180,"props":560,"children":562},{"class":182,"line":561},10,[563],{"type":127,"tag":180,"props":564,"children":565},{"style":496},[566],{"type":138,"value":567},"       *\n",{"type":127,"tag":180,"props":569,"children":571},{"class":182,"line":570},11,[572,577,582,588],{"type":127,"tag":180,"props":573,"children":574},{"style":496},[575],{"type":138,"value":576},"       * ",{"type":127,"tag":180,"props":578,"children":579},{"style":287},[580],{"type":138,"value":581},"@",{"type":127,"tag":180,"props":583,"children":585},{"style":584},"--shiki-light:#9C3EDA;--shiki-light-font-style:italic;--shiki-default:#9C3EDA;--shiki-default-font-style:italic;--shiki-dark:#C792EA;--shiki-dark-font-style:italic",[586],{"type":138,"value":587},"default",{"type":127,"tag":180,"props":589,"children":591},{"style":590},"--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#90A4AE;--shiki-default-font-style:italic;--shiki-dark:#BABED8;--shiki-dark-font-style:italic",[592],{"type":138,"value":593}," `['stores']`\n",{"type":127,"tag":180,"props":595,"children":597},{"class":182,"line":596},12,[598],{"type":127,"tag":180,"props":599,"children":600},{"style":496},[601],{"type":138,"value":602},"       */\n",{"type":127,"tag":180,"props":604,"children":605},{"class":182,"line":39},[606,611,615],{"type":127,"tag":180,"props":607,"children":608},{"style":319},[609],{"type":138,"value":610},"        storesDirs",{"type":127,"tag":180,"props":612,"children":613},{"style":310},[614],{"type":138,"value":272},{"type":127,"tag":180,"props":616,"children":617},{"style":304},[618],{"type":138,"value":619}," []\n",{"type":127,"tag":180,"props":621,"children":622},{"class":182,"line":35},[623],{"type":127,"tag":180,"props":624,"children":625},{"style":310},[626],{"type":138,"value":627},"    }\n",{"type":127,"tag":180,"props":629,"children":631},{"class":182,"line":630},15,[632,636],{"type":127,"tag":180,"props":633,"children":634},{"style":310},[635],{"type":138,"value":362},{"type":127,"tag":180,"props":637,"children":638},{"style":304},[639],{"type":138,"value":367},{"type":127,"tag":150,"props":641,"children":643},{"id":642},"license",[644],{"type":138,"value":645},"License",{"type":127,"tag":144,"props":647,"children":648},{},[649],{"type":127,"tag":650,"props":651,"children":655},"a",{"href":652,"rel":653},"http://opensource.org/licenses/MIT",[654],"nofollow",[656],{"type":138,"value":657},"MIT",{"type":127,"tag":659,"props":660,"children":661},"style",{},[662],{"type":138,"value":663},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":11,"searchDepth":96,"depth":96,"links":665},[666,667,668,669],{"id":152,"depth":96,"text":155},{"id":214,"depth":96,"text":217},{"id":370,"depth":96,"text":373},{"id":642,"depth":96,"text":645},{"v5":671,"v4":672,"v3":673,"v2":674},"5 (nightly)","4.4.4","3.21.4","2.18.1"]