-
Notifications
You must be signed in to change notification settings - Fork 46
feat: datastore vue3 hooks and example #1072
Conversation
todo: query hook
todo: example on vue and test vue hooks
feat: vue hooks (full crud) todo: sync is not working correctly
bug: requests to server is not valid
fix: create new item typings
fix: add vue as peer dependency
@Arenukvern Amazing work. I'm not that much familiar with the Vue but will get into this soon. @kingsleyzissou would you have time to check this out. Amazing PR overal! |
Hey @Arenukvern awesome stuff! I haven't used Vue since Vue 2, so it's been a while. I'm going to take my time to review this. Thanks for submitting the PR! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @Arenukvern this is great stuff. Do you mind fixing the lint errors and I can approve this and get it merged.
I verified this with the Vue sample app and the React sample app and both are working
@kingsleyzissou yes, thank you very much for the preview! |
Rebase needed. You can simply change path - we moved repo structure |
@kingsleyzissou maybe you can help with this somehow to not let it go stale |
@wtrocki sorry for long time fix. |
Good day!
I would like to make PR to add vue3 support in this awesome project.
Description
Hooks for vue3 for Add, Save, Update, Query
Refactored from react hooks and following the same names conventions.
As Vue3 hooks names conflict with react names it was exported into one namespace useDatastoreHooks
path:
offix/packages/datastore/datastore/src/vue
test: As same as react available in
offix/packages/datastore/datastore/tests
Vue3 + vite + antd example to use vue3 hooks
Refactored from react example.
path:
offix/examples/vue-datastore
Problems:
Solved problems but maybe in a wrong way:
_version
and_lastUpdatedAt
fields in example project cannot be created automaticaly. It was solved just adding new field in runtime.graphql modelsindex.d.ts
which solved by setting "skipLibCheck": true intsconfig
tsconfig.lib
Checklist
npm test
passesnpm run build
works