import { defineStore } from 'pinia' ; export const useMainStore = defineStore ( { id : 'main' , state : ( ) => ( { counter : 0 , name : 'Eduardo' , } ) , getters : { doubleCount ( ) { return this . counter * 2 ; } , doubleCountPlusOne ( ) { return this . doubleCount * 2 ; } , } , actions : { reset ( ) { this . counter = 0 ; } , } , } ) ;