CodeDredd / pinia-orm

The Pinia plugin to enable Object-Relational Mapping access to the Pinia Store.
https://pinia-orm.codedredd.de/
MIT License
425 stars 36 forks source link

Documentation for decorator import #1850

Closed oaubert closed 2 weeks ago

oaubert commented 2 weeks ago

Environment

Operating System - Linux(6.7.12-amd64) - linux/x64 NodeJs - 20.11.1

Global packages NPM - 10.2.4 yarn - 1.22.19 @quasar/cli - undefined @quasar/icongenie - Not installed cordova - Not installed

Important local packages quasar - 2.16.4 -- Build high-performance VueJS user interfaces (SPA, PWA, SSR, Mobile and Desktop) in record time @quasar/app-vite - 1.9.3 -- Quasar Framework App CLI with Vite @quasar/extras - 1.16.11 -- Quasar Framework fonts, icons and animations eslint-plugin-quasar - Not installed vue - 3.4.27 -- The progressive JavaScript framework for building modern web UI. vue-router - 4.3.2 pinia - 2.1.7 -- Intuitive, type safe and flexible Store for Vue vuex - Not installed vite - 2.9.18 -- Native-ESM powered web dev build tool eslint - 8.57.0 -- An AST-based pattern checker for JavaScript.

Reproduction

Documentation issue

Describe the bug

The current documentation for defining models states that decorator imports should be

import { Uid } from 'pinia-orm/decorators'

but with pinia 1.9.0, the module layout changed and it should instead be

import { Uid } from 'pinia-orm/dist/decorators'

as I discovered after some time, digging into the documentation for 1.9.1 (in https://github.com/CodeDredd/pinia-orm/pull/1842 )

Additional context

No response

Logs

No response

CodeDredd commented 2 weeks ago

I think you will find your answer here: https://github.com/CodeDredd/pinia-orm/issues/1774#issuecomment-1935894018 I should propbably add this add some point to the docs.