opnform/client/stores/errors.js

16 lines
252 B
JavaScript

import { defineStore } from 'pinia'
export const useErrorsStore = defineStore('errors', {
state: () => ({
content: null
}),
actions: {
set (error) {
this.content = error
},
clear () {
this.content = null
}
}
})