\r\nimport { defineConfig } from 'vite'\r\nimport vue from '@vitejs/plugin-vue'\r\nimport vueI18n from '@intlify/vite-plugin-vue-i18n'\r\n\r\n// https://vitejs.dev/config/\r\nconst path = require(\"path\")\r\nexport default defineConfig({\r\n test: {\r\n setupFiles: ['./tests/config.ts']\r\n },\r\n optimizeDeps: {\r\n exclude: ['vue-demi']\r\n },\r\n build: {\r\n lib: {\r\n entry: path.resolve(__dirname, 'src/install.ts'),\r\n name: 'vcp',\r\n formats: ['umd'],\r\n fileName: (format) => `vcp.${format}.ts`\r\n },\r\n rollupOptions: {\r\n external: ['vue', 'vueI18n', 'vue-demi',],\r\n output: {\r\n exports: 'named',\r\n globals: {\r\n 'vue-demi': 'VueDemi',\r\n 'vue': 'Vue',\r\n }\r\n }\r\n },\r\n },\r\n plugins: [\r\n vue({\r\n style: true,\r\n css: true\r\n }),\r\n vueI18n({\r\n include: path.resolve(__dirname, 'src/assets/translations.ts'),\r\n globalSFCScope: true,\r\n compositionOnly: false,\r\n }),\r\n ],\r\n server: {\r\n port: 8080\r\n },\r\n resolve: {\r\n dedupe: ['vue'],\r\n alias: {\r\n \"~\": path.resolve(__dirname, \"./src\"),\r\n \"@\": path.resolve(__dirname, \"./src\"),\r\n },\r\n },\r\n})\r\n\r\n```\r\n\r\npackage.json:\r\n```\r\n{\r\n \"name\": \"vcp\",\r\n \"version\": \"0.9.14\",\r\n \"private\": false,\r\n \"author\": \"Alireza Safari \u003Calireza.safaree@gmail.com> (http://alireza-safari.ir)\",\r\n \"license\": \"MIT\",\r\n \"main\": \"./dist/vcp.umd.ts\",\r\n \"description\": \"Vue Client Print with Template Builder\",\r\n \"exports\": {\r\n \".\": {\r\n \"require\": \"./dist/vcp.umd.ts\"\r\n },\r\n \"./dist/style.css\": \"./dist/style.css\"\r\n },\r\n \"keywords\": [\r\n \"vcp\",\r\n \"vue print\",\r\n \"vue client print\",\r\n \"template builder\",\r\n \"vue report\",\r\n \"vue report generator\"\r\n ],\r\n \"files\": [\r\n \"dist/*\"\r\n ],\r\n \"repository\": {\r\n \"type\": \"git\",\r\n \"url\": \"https://github.com/alireza0sfr/vue-client-print\"\r\n },\r\n \"scripts\": {\r\n \"dev\": \"vite\",\r\n \"build\": \"vite build\",\r\n \"serve\": \"vite preview\",\r\n \"test\": \"vitest run --environment jsdom\",\r\n \"test:ui:\": \"vitest --environment jsdom --ui\",\r\n \"test:coverage\": \"vitest run --coverage --environment jsdom\",\r\n \"test:watch\": \"vitest --environment jsdom\"\r\n },\r\n \"dependencies\": {\r\n \"dom-to-image\": \"^2.6.0\",\r\n \"file-saver\": \"^2.0.5\",\r\n \"jsdom\": \"^19.0.0\",\r\n \"print-js\": \"^1.6.0\",\r\n \"register-service-worker\": \"^1.7.2\",\r\n \"typescript\": \"^4.7.2\",\r\n \"vitest\": \"^0.12.9\",\r\n \"vue-demi\": \"^0.12.5\",\r\n \"vue-i18n\": \"^9.1.10\"\r\n },\r\n \"peerDependencies\": {\r\n \"vue\": \">=2.0.0 || >=3.0.0\"\r\n },\r\n \"devDependencies\": {\r\n \"@intlify/vite-plugin-vue-i18n\": \"^3.4.0\",\r\n \"@vitejs/plugin-vue\": \"^2.3.3\",\r\n \"@vitest/ui\": \"^0.12.9\",\r\n \"@vue/compiler-sfc\": \"^3.2.36\",\r\n \"@vue/test-utils\": \"^2.0.0-rc.18\",\r\n \"c8\": \"^7.11.3\",\r\n \"cz-conventional-changelog\": \"^3.0.1\",\r\n \"vite\": \"^2.9.9\",\r\n \"vue\": \"^3.2.36\"\r\n }\r\n}\r\n\r\n```",[],161,"createElementVNode is not a function vite","2022-10-27T15:14:22Z","https://github.com/vueuse/vue-demi/issues/161",0.75280106,{"description":3099,"labels":3100,"number":1995,"owner":3067,"repository":3068,"state":3101,"title":3102,"updated_at":3103,"url":3104,"score":3105},"I'm using vue 2 as default and when switching to vue 3 with `npx vue-demi-switch 3` getting a `selfHook.bind is not a function` error",[],"closed","selfHook.bind is not a function","2021-07-15T17:16:00Z","https://github.com/vueuse/vue-demi/issues/50",0.70392716,{"description":3107,"labels":3108,"number":3109,"owner":3067,"repository":3067,"state":3101,"title":3110,"updated_at":3111,"url":3112,"score":3113},"Will you consider a Vue 3 only version in the future that does not use Vue Demi?",[],962,"Vue 3 only version","2021-11-25T02:52:47Z","https://github.com/vueuse/vueuse/issues/962",0.7230427,{"description":3115,"labels":3116,"number":3120,"owner":3067,"repository":3067,"state":3101,"title":3121,"updated_at":3122,"url":3123,"score":3124},"### Clear and concise description of the problem\n\nAs a developer using VueUse I want to be able to use useRouteQuery out of the box, so that I don't have to pass nuxt' `useRoute` and `useRouter` composables to every `useRouteQuery` call I make.\r\n\r\nCurrently @vueuse/router uses `useRoute` and `useRouter` from vue-router by default. This however doesn't seem to work when using nuxt3. At the moment it's possible to fix this by passing the equivalent composables from nuxt as options to the composable. Ideally this would already happen in the implementation directly.\n\n### Suggested solution\n\nMaybe there could be a dedicated @vue/nuxt-router package that is virtually identical to the current vue-router implementation, but overwrites the default parameters with nuxt' equivalents.\n\n### Alternative\n\n_No response_\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [X] Follow our [Code of Conduct](https://github.com/vueuse/vueuse/blob/main/CODE_OF_CONDUCT.md)\n- [X] Read the [Contributing Guidelines](https://github.com/vueuse/vueuse/blob/main/CONTRIBUTING.md).\n- [X] Read the [docs](https://vueuse.org/guide).\n- [X] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.",[3117],{"name":3118,"color":3119},"enhancement","a2eeef",2334,"@vueuse/router support for nuxt","2022-12-24T17:04:59Z","https://github.com/vueuse/vueuse/issues/2334",0.7354069,{"description":3126,"labels":3127,"number":19,"owner":3067,"repository":3068,"state":3101,"title":3128,"updated_at":3129,"url":3130,"score":3131},"## Summary\r\n\r\nI tried using `vue-demi-switch 2 vue2` and defining `\"vue2\": \"npm:vue@2\"` in my package.json, but when I run tests, the `@vue/composition-api` breaks, because it imports Vue as `var Vue = require('vue');`\r\n\r\nDo you have any advice on how to proceed with this? I saw `vueuse/core` uses this approach but I couldnt see if you have a fix for this.\r\n\r\nYou can see this in https://github.com/vuelidate/vuelidate/tree/next",[],"Switching between Vue 2 and Vue 3 to run tests with Composition API","2022-07-06T17:23:19Z","https://github.com/vueuse/vue-demi/issues/38",0.73897374,{"description":3133,"labels":3134,"number":3135,"owner":3067,"repository":3067,"state":3101,"title":3136,"updated_at":3137,"url":3138,"score":3139},"I've created a project with vite+vue2(using plugin)+vueuse and it looks like vueuse doesn't work properly in this setup.\r\n\r\nThe error I get:\r\n\r\n```\r\nvue.runtime.esm.js:619 [Vue warn]: Error in data(): \"ReferenceError: ref3 is not defined\"\r\n\r\nfound in\r\n\r\n---> \u003CAnonymous>\r\n \u003CRoot>\r\nwarn @ vue.runtime.esm.js:619\r\nvue.runtime.esm.js:1888 ReferenceError: ref3 is not defined\r\n at Object.ref (index.esm.js:1)\r\n at useCounter (index.esm.js:698)\r\n at setup (App.vue:21)\r\n at mergedSetupFn (vue-composition-api.esm.js:1741)\r\n at vue-composition-api.esm.js:1527\r\n at activateCurrentInstance (vue-composition-api.esm.js:1454)\r\n at initSetup (vue-composition-api.esm.js:1525)\r\n at VueComponent.wrappedData (vue-composition-api.esm.js:1509)\r\n at getData (vue.runtime.esm.js:4748)\r\n at initData (vue.runtime.esm.js:4705)\r\n```\r\n\r\nI tried `useCounter` and `useStorage`, but I think it can be replicated with other methods.\r\n\r\nHere is the project link to replicate: \r\nhttps://github.com/localhost5001/vite-vue2-vueuse-template",[],485,"Incompatible with vite and vue2","2021-05-05T20:52:10Z","https://github.com/vueuse/vueuse/issues/485",0.7513766,{"description":3141,"labels":3142,"number":3144,"owner":3067,"repository":3067,"state":3101,"title":3145,"updated_at":3146,"url":3147,"score":3148},"### Clear and concise description of the problem\n\nI'm still writing some code projects in Vue 2, and I'd love to have all the Vue 3 goodness I can.\r\nSpecifically, I have two tables on the same page, and I want to be able to watch the route query params for both tables independently.\n\n### Suggested solution\n\nUsing `import { useRoute, useRouter } from \"vue2-helpers/vue-route` I have been able to back-port @vueuse/router -> useRouteQuery to Vue 2.\r\n\r\nI'd love it if this could be come a standard thing, rather than having to role my own. \n\n### Alternative\n\n_No response_\n\n### Additional context\n\nSee https://github.com/icefoganalytics/travel-authorization/commit/f899f10013a6e3116c149ccf0b6a760a78d89bca\n\n### Validations\n\n- [X] Follow our [Code of Conduct](https://github.com/vueuse/vueuse/blob/main/CODE_OF_CONDUCT.md)\n- [X] Read the [Contributing Guidelines](https://github.com/vueuse/vueuse/blob/main/CONTRIBUTING.md).\n- [X] Read the [docs](https://vueuse.org/guide).\n- [X] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.",[3143],{"name":3118,"color":3119},4117,"Request of Backport of `@vueuse/router` -> `useRouteQuery` to Vue 2","2024-07-26T15:24:34Z","https://github.com/vueuse/vueuse/issues/4117",0.7543777,["Reactive",3150],{},["Set"],["ShallowReactive",3153],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$fH9Tg1A5E_E7yehCDQu7jmnoX4BY12MeLYWDau-1FWxc":-1},"/vueuse/vue-demi/34"]