We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No response
vue
pinia
pinia-orm
import { createPinia, setActivePinia } from "pinia" import { createORM, Model, useRepo, definePiniaOrmPlugin } from "pinia-orm" import { createApp } from "vue" const customPlugin = () => definePiniaOrmPlugin((...args) => { console.log(args) return args[0] }) const app = createApp({}) const pinia = createPinia() .use( createORM({ plugins: [ customPlugin(), ] }) ) app.use(pinia) setActivePinia(pinia) class Test extends Model { static entity = 'test' static fields() { return { id: this.uid(), firstName: this.string(), lastName: this.string(), email: this.string(), } } } console.log(useRepo(Test))
node example.js
Repository { database: Database { models: { test: [Test] } }, model: Test { pivot: undefined }, pinia: undefined, queryCache: WeakCache { [Symbol(Symbol.toStringTag)]: undefined }, hydratedDataCache: Map(0) {}, use: undefined, config: { model: { namespace: '', withMeta: false, hidden: [Array], visible: [Array] }, cache: { shared: true, provider: [class WeakCache] } } }
Plugin system might not working.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Environment
No response
Reproduction
vue
,pinia
,pinia-orm
.example.js
Output
Describe the bug
Plugin system might not working.
Additional context
No response
Logs
No response
The text was updated successfully, but these errors were encountered: