From dff09a4bdbe9c7cdbae26c6dae833c6684ceb109 Mon Sep 17 00:00:00 2001 From: Siddharth Kothari Date: Wed, 3 Jan 2024 21:33:52 +0530 Subject: [PATCH 1/3] fix: strict selection behavior to only allow picking from suggestions --- .../vue/src/components/search/DataSearch.jsx | 58 ++++++++++++++----- 1 file changed, 44 insertions(+), 14 deletions(-) diff --git a/packages/vue/src/components/search/DataSearch.jsx b/packages/vue/src/components/search/DataSearch.jsx index 799c8b2b6..0fa0276e5 100644 --- a/packages/vue/src/components/search/DataSearch.jsx +++ b/packages/vue/src/components/search/DataSearch.jsx @@ -77,6 +77,7 @@ const DataSearch = { isOpen: false, normalizedSuggestions: [], isPending: false, + isSuggestionSelected: false, }; this.internalComponent = `${props.componentId}__internal`; return this.__state; @@ -534,6 +535,7 @@ const DataSearch = { this.getRecentSearches(); } if (isTagsMode) { + let isTagAdded = false; if (Array.isArray(this.selectedTags) && this.selectedTags.length) { // check if value already present in selectedTags if (typeof value === 'string' && this.selectedTags.includes(value)) { @@ -543,14 +545,36 @@ const DataSearch = { this.selectedTags = [...this.selectedTags]; if (typeof value === 'string' && !!value) { - this.selectedTags.push(value); + if (props.strictSelection && cause === causes.SUGGESTION_SELECT) { + this.selectedTags.push(value); + isTagAdded = true; + } else if (!props.strictSelection) { + this.selectedTags.push(value); + isTagAdded = true; + } } else if (Array.isArray(value) && !isEqual(this.selectedTags, value)) { - this.selectedTags = value; + if (props.strictSelection && cause === causes.SUGGESTION_SELECT) { + this.selectedTags = value; + isTagAdded = true; + } else if (!props.strictSelection) { + this.selectedTags.push(value); + isTagAdded = true; + } } } else if (value) { - this.selectedTags = typeof value !== 'string' ? value : [...value]; + if (props.strictSelection && cause === causes.SUGGESTION_SELECT) { + this.selectedTags = typeof value !== 'string' ? value : [...value]; + isTagAdded = true; + } else if (!props.strictSelection) { + this.selectedTags = typeof value !== 'string' ? value : [...value]; + isTagAdded = true; + } + } + if (props.strictSelection && !isTagAdded) { + this.currentValue = value; + } else { + this.currentValue = ''; } - this.currentValue = ''; } else { this.currentValue = value; } @@ -574,7 +598,7 @@ const DataSearch = { if (props.strictSelection && props.autosuggest) { if (cause === causes.SUGGESTION_SELECT || props.value !== undefined) { this.updateQueryHandler(props.componentId, queryHandlerValue, props); - } else if (this.currentValue !== '') { + } else if (this.currentValue !== '' && !props.strictSelection) { this.setValue('', true); } } else { @@ -719,7 +743,7 @@ const DataSearch = { handleKeyDown(event, highlightedIndex) { const { value: targetValue } = event.target; - const { value, strictSelection, size, autosuggest } = this.$props; + const { value, size } = this.$props; if (value !== undefined) { this.isPending = true; } @@ -736,14 +760,16 @@ const DataSearch = { ].length) ) { this.isPending = false; - this.setValue( - this.$options.isTagsMode && autosuggest && strictSelection ? '' : targetValue, - true, - this.$props, - undefined, - false, - ); - this.onValueSelectedHandler(targetValue, causes.ENTER_PRESS); + if (!this.isSuggestionSelected) { + this.setValue( + targetValue, + true, + this.$props, + undefined, + false, + ); + this.onValueSelectedHandler(targetValue, causes.ENTER_PRESS); + } } // Need to review this.$emit('keyDown', event, this.triggerQuery); @@ -785,6 +811,10 @@ const DataSearch = { this.triggerClickAnalytics(suggestion._click_id); if (value === undefined) { this.setValue(suggestion.value, true, this.$props, causes.SUGGESTION_SELECT); + this.isSuggestionSelected = true; + setTimeout(() => { + this.isSuggestionSelected = false; + }, 50); } else if (this.$options.isTagsMode) { const emitValue = Array.isArray(this.selectedTags) ? [...this.selectedTags] : []; if (this.selectedTags.includes(suggestion.value)) { From 874fdff15ddd3d5ff8a9d4657c553e20e9ace589 Mon Sep 17 00:00:00 2001 From: Siddharth Kothari Date: Thu, 4 Jan 2024 00:28:14 +0530 Subject: [PATCH 2/3] fix: strict selection behavior to only allow picking from suggestions for SearchBox --- .../vue/src/components/search/SearchBox.jsx | 62 ++++++++++++++----- 1 file changed, 48 insertions(+), 14 deletions(-) diff --git a/packages/vue/src/components/search/SearchBox.jsx b/packages/vue/src/components/search/SearchBox.jsx index 02637ba57..d097894ea 100644 --- a/packages/vue/src/components/search/SearchBox.jsx +++ b/packages/vue/src/components/search/SearchBox.jsx @@ -63,6 +63,7 @@ const SearchBox = { selectedTags: [], isOpen: false, normalizedSuggestions: [], + isSuggestionSelected: false, }; this.internalComponent = `${props.componentId}__internal`; return this.__state; @@ -307,7 +308,9 @@ const SearchBox = { if (this.$options.isTagsMode) { cause = causes.SUGGESTION_SELECT; } - this.setValue(newVal || '', true, this.$props, cause); + if (!this.isSuggestionSelected) { + this.setValue(newVal || '', true, this.$props, cause); + } } }, focusShortcuts() { @@ -433,10 +436,11 @@ const SearchBox = { categoryValue = undefined, ) { const performUpdate = () => { + let isTagAdded = false; if (this.$options.isTagsMode && isEqual(value, this.selectedTags)) { return; } - if (this.$options.isTagsMode && cause === causes.SUGGESTION_SELECT) { + if (this.$options.isTagsMode) { if (Array.isArray(this.selectedTags) && this.selectedTags.length) { // check if value already present in selectedTags if (typeof value === 'string' && this.selectedTags.includes(value)) { @@ -446,14 +450,36 @@ const SearchBox = { this.selectedTags = [...this.selectedTags]; if (typeof value === 'string' && !!value) { - this.selectedTags.push(value); + if (props.strictSelection && cause === causes.SUGGESTION_SELECT) { + this.selectedTags.push(value); + isTagAdded = true; + } else if (!props.strictSelection) { + this.selectedTags.push(value); + isTagAdded = true; + } } else if (Array.isArray(value) && !isEqual(this.selectedTags, value)) { - this.selectedTags = value; + if (props.strictSelection && cause === causes.SUGGESTION_SELECT) { + this.selectedTags = value; + isTagAdded = true; + } else if (!props.strictSelection) { + this.selectedTags.push(value); + isTagAdded = true; + } } } else if (value) { - this.selectedTags = typeof value !== 'string' ? value : [...value]; + if (props.strictSelection && cause === causes.SUGGESTION_SELECT) { + this.selectedTags = typeof value !== 'string' ? value : [...value]; + isTagAdded = true; + } else if (!props.strictSelection) { + this.selectedTags = typeof value !== 'string' ? value : [...value]; + isTagAdded = true; + } + } + if (props.strictSelection && !isTagAdded) { + this.currentValue = value; + } else { + this.currentValue = ''; } - this.currentValue = ''; } else { this.currentValue = decodeHtml(value); } @@ -471,11 +497,16 @@ const SearchBox = { if (toggleIsOpen) { this.isOpen = false; } - if (typeof this.currentValue === 'string') - this.triggerDefaultQuery(this.currentValue); + if (typeof this.currentValue === 'string') { + if (this.$options.isTagsMode && props.strictSelection && isTagAdded) { + this.triggerDefaultQuery(this.currentValue); + } else if (!this.$options.isTagsMode) { + this.triggerDefaultQuery(this.currentValue); + } + } } // in case of strict selection only SUGGESTION_SELECT should be able // to set the query otherwise the value should reset - if (props.strictSelection) { + if (this.$options.isTagsMode && props.strictSelection && isTagAdded) { if ( cause === causes.SUGGESTION_SELECT || (this.$options.isTagsMode @@ -486,14 +517,14 @@ const SearchBox = { queryHandlerValue, this.$options.isTagsMode ? undefined : categoryValue, ); - } else { + } else if (!props.strictSelection) { this.setValue('', true); } - } else if ( + } else if (!this.$options.isTagsMode && ( props.value === undefined || cause === causes.SUGGESTION_SELECT || cause === causes.CLEAR_VALUE - ) { + )) { this.triggerCustomQuery( queryHandlerValue, this.$options.isTagsMode ? undefined : categoryValue, @@ -628,11 +659,15 @@ const SearchBox = { if (this.$props.autosuggest === false) { this.enterButtonOnClick(); } else if (highlightedIndex === null) { + this.isSuggestionSelected = true; + setTimeout(() => { + this.isSuggestionSelected = false; + }, 50); this.setValue( event.target.value, true, this.$props, - this.$options.isTagsMode ? causes.SUGGESTION_SELECT : undefined, // to handle tags + undefined, // to handle tags ); this.onValueSelectedHandler(event.target.value, causes.ENTER_PRESS); } @@ -699,7 +734,6 @@ const SearchBox = { } emitValue.push(suggestion.value); } - this.setValue( emitValue, true, From 066b88e39d41133c4e63f2cadb8bdb6675697cfb Mon Sep 17 00:00:00 2001 From: Siddharth Kothari Date: Thu, 4 Jan 2024 00:45:52 +0530 Subject: [PATCH 3/3] chore: update examples to new lib version --- packages/vue/demos/good-books/package.json | 2 +- .../examples/analytics-with-hook/package.json | 2 +- .../package.json | 2 +- .../vue/examples/data-search/package.json | 2 +- .../dynamic-range-slider/package.json | 2 +- .../mongo-examples/data-search/package.json | 2 +- .../mongo-examples/multi-list/package.json | 2 +- .../mongo-examples/range-input/package.json | 2 +- .../vue/examples/multi-Range/package.json | 2 +- .../examples/multi-dropdown-list/package.json | 2 +- .../examples/multi-list-nested/package.json | 2 +- packages/vue/examples/multi-list/package.json | 2 +- .../vue/examples/preferences/package.json | 2 +- .../vue/examples/range-input/package.json | 2 +- .../vue/examples/range-slider/package.json | 2 +- .../package.json | 2 +- .../examples/reactive-component/package.json | 2 +- .../package.json | 2 +- .../package.json | 2 +- .../reactive-google-map-nuxt/package.json | 2 +- .../examples/reactive-google-map/package.json | 2 +- .../package.json | 2 +- .../vue/examples/reactive-list/package.json | 2 +- .../package.json | 2 +- .../package.json | 2 +- .../vue/examples/result-card/package.json | 2 +- .../vue/examples/result-list/package.json | 2 +- .../vue/examples/saved-search/package.json | 2 +- packages/vue/examples/search-box/package.json | 2 +- .../selected-filters-custom/package.json | 2 +- .../single-dropdown-list/package.json | 2 +- .../vue/examples/single-list/package.json | 2 +- .../vue/examples/single-range/package.json | 2 +- .../vue/examples/toggle-button/package.json | 2 +- .../with-nuxt-typescript/.nuxt/app.config.mjs | 20 + .../.nuxt/components.d.ts | 92 ++++ .../with-nuxt-typescript/.nuxt/imports.d.ts | 24 + .../with-nuxt-typescript/.nuxt/nuxt.d.ts | 21 + .../.nuxt/schema/nuxt.schema.d.ts | 17 + .../.nuxt/schema/nuxt.schema.json | 3 + .../with-nuxt-typescript/.nuxt/tsconfig.json | 100 +++++ .../.nuxt/tsconfig.server.json | 70 +++ .../.nuxt/types/app.config.d.ts | 33 ++ .../.nuxt/types/imports.d.ts | 412 ++++++++++++++++++ .../.nuxt/types/layouts.d.ts | 7 + .../.nuxt/types/middleware.d.ts | 7 + .../.nuxt/types/nitro-config.d.ts | 14 + .../.nuxt/types/nitro-imports.d.ts | 121 +++++ .../.nuxt/types/nitro-nuxt.d.ts | 26 ++ .../.nuxt/types/nitro-routes.d.ts | 11 + .../.nuxt/types/nitro.d.ts | 3 + .../.nuxt/types/plugins.d.ts | 27 ++ .../.nuxt/types/schema.d.ts | 25 ++ .../.nuxt/types/vue-shim.d.ts | 5 + .../.nuxt/vue-router-stub.d.ts | 1 + packages/vue/examples/with-nuxt/package.json | 2 +- packages/vue/examples/with-ssr/package.json | 2 +- .../examples/with-tailwind-css/package.json | 2 +- 58 files changed, 1076 insertions(+), 37 deletions(-) create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/app.config.mjs create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/components.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/imports.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/nuxt.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/schema/nuxt.schema.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/schema/nuxt.schema.json create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/tsconfig.json create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/tsconfig.server.json create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/app.config.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/imports.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/layouts.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/middleware.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-config.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-imports.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-nuxt.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-routes.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/plugins.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/schema.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/types/vue-shim.d.ts create mode 100644 packages/vue/examples/with-nuxt-typescript/.nuxt/vue-router-stub.d.ts diff --git a/packages/vue/demos/good-books/package.json b/packages/vue/demos/good-books/package.json index 3d55a8a1f..1a1dde6e5 100644 --- a/packages/vue/demos/good-books/package.json +++ b/packages/vue/demos/good-books/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/analytics-with-hook/package.json b/packages/vue/examples/analytics-with-hook/package.json index a374b727f..2574b5db2 100644 --- a/packages/vue/examples/analytics-with-hook/package.json +++ b/packages/vue/examples/analytics-with-hook/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/data-search-custom-suggestions/package.json b/packages/vue/examples/data-search-custom-suggestions/package.json index cf2394fa3..1a3151ade 100644 --- a/packages/vue/examples/data-search-custom-suggestions/package.json +++ b/packages/vue/examples/data-search-custom-suggestions/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/data-search/package.json b/packages/vue/examples/data-search/package.json index 545c44cdc..fda46f8b5 100644 --- a/packages/vue/examples/data-search/package.json +++ b/packages/vue/examples/data-search/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/dynamic-range-slider/package.json b/packages/vue/examples/dynamic-range-slider/package.json index 22f6a5c60..2f38aa802 100644 --- a/packages/vue/examples/dynamic-range-slider/package.json +++ b/packages/vue/examples/dynamic-range-slider/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/mongo-examples/data-search/package.json b/packages/vue/examples/mongo-examples/data-search/package.json index 7f9352b85..83cd35846 100644 --- a/packages/vue/examples/mongo-examples/data-search/package.json +++ b/packages/vue/examples/mongo-examples/data-search/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/mongo-examples/multi-list/package.json b/packages/vue/examples/mongo-examples/multi-list/package.json index e6b2d0f20..95ca4ecc7 100644 --- a/packages/vue/examples/mongo-examples/multi-list/package.json +++ b/packages/vue/examples/mongo-examples/multi-list/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/mongo-examples/range-input/package.json b/packages/vue/examples/mongo-examples/range-input/package.json index c8a04eff7..7f98184a7 100644 --- a/packages/vue/examples/mongo-examples/range-input/package.json +++ b/packages/vue/examples/mongo-examples/range-input/package.json @@ -8,7 +8,7 @@ "lint": "vue-cli-service lint" }, "dependencies": { - "@appbaseio/reactivesearch-vue": "1.35.2", + "@appbaseio/reactivesearch-vue": "1.35.3", "vue": "^2.7.7" }, "devDependencies": { diff --git a/packages/vue/examples/multi-Range/package.json b/packages/vue/examples/multi-Range/package.json index 0be1f8b4f..c306b8d0c 100644 --- a/packages/vue/examples/multi-Range/package.json +++ b/packages/vue/examples/multi-Range/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/multi-dropdown-list/package.json b/packages/vue/examples/multi-dropdown-list/package.json index 231075d5b..db1d9ccf4 100644 --- a/packages/vue/examples/multi-dropdown-list/package.json +++ b/packages/vue/examples/multi-dropdown-list/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/multi-list-nested/package.json b/packages/vue/examples/multi-list-nested/package.json index 10a84af54..d92644e1e 100644 --- a/packages/vue/examples/multi-list-nested/package.json +++ b/packages/vue/examples/multi-list-nested/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/multi-list/package.json b/packages/vue/examples/multi-list/package.json index e1cce4d04..22c49f2e2 100644 --- a/packages/vue/examples/multi-list/package.json +++ b/packages/vue/examples/multi-list/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/preferences/package.json b/packages/vue/examples/preferences/package.json index 5dfc97bf3..541c3edf9 100644 --- a/packages/vue/examples/preferences/package.json +++ b/packages/vue/examples/preferences/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2", + "@appbaseio/reactivesearch-vue": "1.35.3", "vuejs-paginate": "^2.1.0" }, "devDependencies": { diff --git a/packages/vue/examples/range-input/package.json b/packages/vue/examples/range-input/package.json index a0ae73d9d..2f4c7b3a1 100644 --- a/packages/vue/examples/range-input/package.json +++ b/packages/vue/examples/range-input/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/range-slider/package.json b/packages/vue/examples/range-slider/package.json index fa44cc826..8a62a0abb 100644 --- a/packages/vue/examples/range-slider/package.json +++ b/packages/vue/examples/range-slider/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/reactive-component-with-custom-query/package.json b/packages/vue/examples/reactive-component-with-custom-query/package.json index edd471568..9ea5898e5 100644 --- a/packages/vue/examples/reactive-component-with-custom-query/package.json +++ b/packages/vue/examples/reactive-component-with-custom-query/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/reactive-component/package.json b/packages/vue/examples/reactive-component/package.json index 83400bb80..d238a6823 100644 --- a/packages/vue/examples/reactive-component/package.json +++ b/packages/vue/examples/reactive-component/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/reactive-google-map-aggregations/package.json b/packages/vue/examples/reactive-google-map-aggregations/package.json index b5f54add9..411140856 100644 --- a/packages/vue/examples/reactive-google-map-aggregations/package.json +++ b/packages/vue/examples/reactive-google-map-aggregations/package.json @@ -10,7 +10,7 @@ "dependencies": { "core-js": "^3.6.5", "vue": "^2.6.10", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@babel/plugin-proposal-optional-chaining": "^7.18.6", diff --git a/packages/vue/examples/reactive-google-map-default-query/package.json b/packages/vue/examples/reactive-google-map-default-query/package.json index 6c2daa394..5425cd393 100644 --- a/packages/vue/examples/reactive-google-map-default-query/package.json +++ b/packages/vue/examples/reactive-google-map-default-query/package.json @@ -10,7 +10,7 @@ "dependencies": { "core-js": "^3.6.5", "vue": "^2.6.10", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@babel/plugin-proposal-optional-chaining": "^7.18.6", diff --git a/packages/vue/examples/reactive-google-map-nuxt/package.json b/packages/vue/examples/reactive-google-map-nuxt/package.json index 25aec5b1c..26cd9bc18 100644 --- a/packages/vue/examples/reactive-google-map-nuxt/package.json +++ b/packages/vue/examples/reactive-google-map-nuxt/package.json @@ -11,7 +11,7 @@ "generate": "nuxt generate" }, "dependencies": { - "@appbaseio/reactivesearch-vue": "1.35.2", + "@appbaseio/reactivesearch-vue": "1.35.3", "cross-env": "^5.2.0", "nuxt": "^2.0.0" }, diff --git a/packages/vue/examples/reactive-google-map/package.json b/packages/vue/examples/reactive-google-map/package.json index 89fa015ca..6887b45ff 100644 --- a/packages/vue/examples/reactive-google-map/package.json +++ b/packages/vue/examples/reactive-google-map/package.json @@ -8,7 +8,7 @@ "lint": "vue-cli-service lint" }, "dependencies": { - "@appbaseio/reactivesearch-vue": "1.35.2", + "@appbaseio/reactivesearch-vue": "1.35.3", "core-js": "^3.6.5", "vue": "^2.6.10" }, diff --git a/packages/vue/examples/reactive-list-custom-pagination/package.json b/packages/vue/examples/reactive-list-custom-pagination/package.json index fb638b645..320135d69 100644 --- a/packages/vue/examples/reactive-list-custom-pagination/package.json +++ b/packages/vue/examples/reactive-list-custom-pagination/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2", + "@appbaseio/reactivesearch-vue": "1.35.3", "vuejs-paginate": "^2.1.0" }, "devDependencies": { diff --git a/packages/vue/examples/reactive-list/package.json b/packages/vue/examples/reactive-list/package.json index 42a3d09f9..edf39dc91 100644 --- a/packages/vue/examples/reactive-list/package.json +++ b/packages/vue/examples/reactive-list/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2", + "@appbaseio/reactivesearch-vue": "1.35.3", "vuejs-paginate": "^2.1.0" }, "devDependencies": { diff --git a/packages/vue/examples/reactivelist-with-aggregation/package.json b/packages/vue/examples/reactivelist-with-aggregation/package.json index a125c8ae7..dac375bfb 100644 --- a/packages/vue/examples/reactivelist-with-aggregation/package.json +++ b/packages/vue/examples/reactivelist-with-aggregation/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/reactivelist-without-aggregation/package.json b/packages/vue/examples/reactivelist-without-aggregation/package.json index 0ac647fce..060579e48 100644 --- a/packages/vue/examples/reactivelist-without-aggregation/package.json +++ b/packages/vue/examples/reactivelist-without-aggregation/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/result-card/package.json b/packages/vue/examples/result-card/package.json index 5b79da7ce..2a1a83a63 100644 --- a/packages/vue/examples/result-card/package.json +++ b/packages/vue/examples/result-card/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/result-list/package.json b/packages/vue/examples/result-list/package.json index be1467ded..1192347df 100644 --- a/packages/vue/examples/result-list/package.json +++ b/packages/vue/examples/result-list/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/saved-search/package.json b/packages/vue/examples/saved-search/package.json index 9c277e155..2101777bb 100644 --- a/packages/vue/examples/saved-search/package.json +++ b/packages/vue/examples/saved-search/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/search-box/package.json b/packages/vue/examples/search-box/package.json index 31f048890..788a34380 100644 --- a/packages/vue/examples/search-box/package.json +++ b/packages/vue/examples/search-box/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/selected-filters-custom/package.json b/packages/vue/examples/selected-filters-custom/package.json index 7d2219699..933c192ee 100644 --- a/packages/vue/examples/selected-filters-custom/package.json +++ b/packages/vue/examples/selected-filters-custom/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/single-dropdown-list/package.json b/packages/vue/examples/single-dropdown-list/package.json index 04d4fda09..1ce635852 100644 --- a/packages/vue/examples/single-dropdown-list/package.json +++ b/packages/vue/examples/single-dropdown-list/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/single-list/package.json b/packages/vue/examples/single-list/package.json index 7b23b9c9d..c339167cd 100644 --- a/packages/vue/examples/single-list/package.json +++ b/packages/vue/examples/single-list/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/single-range/package.json b/packages/vue/examples/single-range/package.json index 4259b5efe..ba6fc4208 100644 --- a/packages/vue/examples/single-range/package.json +++ b/packages/vue/examples/single-range/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/toggle-button/package.json b/packages/vue/examples/toggle-button/package.json index 9218cd223..808b0fb94 100644 --- a/packages/vue/examples/toggle-button/package.json +++ b/packages/vue/examples/toggle-button/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.7.7", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "^3.0.4", diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/app.config.mjs b/packages/vue/examples/with-nuxt-typescript/.nuxt/app.config.mjs new file mode 100644 index 000000000..f161f1c2f --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/app.config.mjs @@ -0,0 +1,20 @@ + +import { updateAppConfig } from '#app/config' +import { defuFn } from 'defu' + +const inlineConfig = { + "nuxt": { + "buildId": "d36fc3fc-868f-462a-b7af-cc6d9457242a" + } +} + +// Vite - webpack is handled directly in #app/config +if (import.meta.hot) { + import.meta.hot.accept((newModule) => { + updateAppConfig(newModule.default) + }) +} + + + +export default /* #__PURE__ */ defuFn(inlineConfig) diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/components.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/components.d.ts new file mode 100644 index 000000000..153219cb3 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/components.d.ts @@ -0,0 +1,92 @@ +// Generated by components discovery +declare module 'vue' { + export interface GlobalComponents { + 'Search': typeof import("../components/search.vue")['default'] + 'NuxtWelcome': typeof import("../../../../../node_modules/@nuxt/ui-templates/dist/templates/welcome.vue")['default'] + 'NuxtLayout': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-layout")['default'] + 'NuxtErrorBoundary': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-error-boundary")['default'] + 'ClientOnly': typeof import("../../../../../node_modules/nuxt/dist/app/components/client-only")['default'] + 'DevOnly': typeof import("../../../../../node_modules/nuxt/dist/app/components/dev-only")['default'] + 'ServerPlaceholder': typeof import("../../../../../node_modules/nuxt/dist/app/components/server-placeholder")['default'] + 'NuxtLink': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-link")['default'] + 'NuxtLoadingIndicator': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-loading-indicator")['default'] + 'NuxtImg': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-stubs")['NuxtImg'] + 'NuxtPicture': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-stubs")['NuxtPicture'] + 'NuxtPage': typeof import("../../../../../node_modules/nuxt/dist/pages/runtime/page")['default'] + 'NoScript': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['NoScript'] + 'Link': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Link'] + 'Base': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Base'] + 'Title': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Title'] + 'Meta': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Meta'] + 'Style': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Style'] + 'Head': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Head'] + 'Html': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Html'] + 'Body': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Body'] + 'LazySearch': typeof import("../components/search.vue")['default'] + 'LazyNuxtWelcome': typeof import("../../../../../node_modules/@nuxt/ui-templates/dist/templates/welcome.vue")['default'] + 'LazyNuxtLayout': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-layout")['default'] + 'LazyNuxtErrorBoundary': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-error-boundary")['default'] + 'LazyClientOnly': typeof import("../../../../../node_modules/nuxt/dist/app/components/client-only")['default'] + 'LazyDevOnly': typeof import("../../../../../node_modules/nuxt/dist/app/components/dev-only")['default'] + 'LazyServerPlaceholder': typeof import("../../../../../node_modules/nuxt/dist/app/components/server-placeholder")['default'] + 'LazyNuxtLink': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-link")['default'] + 'LazyNuxtLoadingIndicator': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-loading-indicator")['default'] + 'LazyNuxtImg': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-stubs")['NuxtImg'] + 'LazyNuxtPicture': typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-stubs")['NuxtPicture'] + 'LazyNuxtPage': typeof import("../../../../../node_modules/nuxt/dist/pages/runtime/page")['default'] + 'LazyNoScript': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['NoScript'] + 'LazyLink': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Link'] + 'LazyBase': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Base'] + 'LazyTitle': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Title'] + 'LazyMeta': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Meta'] + 'LazyStyle': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Style'] + 'LazyHead': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Head'] + 'LazyHtml': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Html'] + 'LazyBody': typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Body'] + } +} + +export const Search: typeof import("../components/search.vue")['default'] +export const NuxtWelcome: typeof import("../../../../../node_modules/@nuxt/ui-templates/dist/templates/welcome.vue")['default'] +export const NuxtLayout: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-layout")['default'] +export const NuxtErrorBoundary: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-error-boundary")['default'] +export const ClientOnly: typeof import("../../../../../node_modules/nuxt/dist/app/components/client-only")['default'] +export const DevOnly: typeof import("../../../../../node_modules/nuxt/dist/app/components/dev-only")['default'] +export const ServerPlaceholder: typeof import("../../../../../node_modules/nuxt/dist/app/components/server-placeholder")['default'] +export const NuxtLink: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-link")['default'] +export const NuxtLoadingIndicator: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-loading-indicator")['default'] +export const NuxtImg: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-stubs")['NuxtImg'] +export const NuxtPicture: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-stubs")['NuxtPicture'] +export const NuxtPage: typeof import("../../../../../node_modules/nuxt/dist/pages/runtime/page")['default'] +export const NoScript: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['NoScript'] +export const Link: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Link'] +export const Base: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Base'] +export const Title: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Title'] +export const Meta: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Meta'] +export const Style: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Style'] +export const Head: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Head'] +export const Html: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Html'] +export const Body: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Body'] +export const LazySearch: typeof import("../components/search.vue")['default'] +export const LazyNuxtWelcome: typeof import("../../../../../node_modules/@nuxt/ui-templates/dist/templates/welcome.vue")['default'] +export const LazyNuxtLayout: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-layout")['default'] +export const LazyNuxtErrorBoundary: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-error-boundary")['default'] +export const LazyClientOnly: typeof import("../../../../../node_modules/nuxt/dist/app/components/client-only")['default'] +export const LazyDevOnly: typeof import("../../../../../node_modules/nuxt/dist/app/components/dev-only")['default'] +export const LazyServerPlaceholder: typeof import("../../../../../node_modules/nuxt/dist/app/components/server-placeholder")['default'] +export const LazyNuxtLink: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-link")['default'] +export const LazyNuxtLoadingIndicator: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-loading-indicator")['default'] +export const LazyNuxtImg: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-stubs")['NuxtImg'] +export const LazyNuxtPicture: typeof import("../../../../../node_modules/nuxt/dist/app/components/nuxt-stubs")['NuxtPicture'] +export const LazyNuxtPage: typeof import("../../../../../node_modules/nuxt/dist/pages/runtime/page")['default'] +export const LazyNoScript: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['NoScript'] +export const LazyLink: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Link'] +export const LazyBase: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Base'] +export const LazyTitle: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Title'] +export const LazyMeta: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Meta'] +export const LazyStyle: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Style'] +export const LazyHead: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Head'] +export const LazyHtml: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Html'] +export const LazyBody: typeof import("../../../../../node_modules/nuxt/dist/head/runtime/components")['Body'] + +export const componentNames: string[] diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/imports.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/imports.d.ts new file mode 100644 index 000000000..283aee196 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/imports.d.ts @@ -0,0 +1,24 @@ +export { isVue2, isVue3 } from 'vue-demi'; +export { defineNuxtLink } from '#app/components/nuxt-link'; +export { useNuxtApp, defineNuxtPlugin, definePayloadPlugin, useRuntimeConfig, defineAppConfig } from '#app/nuxt'; +export { requestIdleCallback, cancelIdleCallback } from '#app/compat/idle-callback'; +export { useAppConfig, updateAppConfig } from '#app/config'; +export { defineNuxtComponent } from '#app/composables/component'; +export { useAsyncData, useLazyAsyncData, useNuxtData, refreshNuxtData, clearNuxtData } from '#app/composables/asyncData'; +export { useHydration } from '#app/composables/hydrate'; +export { useState, clearNuxtState } from '#app/composables/state'; +export { clearError, createError, isNuxtError, showError, useError } from '#app/composables/error'; +export { useFetch, useLazyFetch } from '#app/composables/fetch'; +export { useCookie } from '#app/composables/cookie'; +export { prerenderRoutes, useRequestHeaders, useRequestEvent, useRequestFetch, setResponseStatus } from '#app/composables/ssr'; +export { onNuxtReady } from '#app/composables/ready'; +export { preloadComponents, prefetchComponents, preloadRouteComponents } from '#app/composables/preload'; +export { abortNavigation, addRouteMiddleware, defineNuxtRouteMiddleware, setPageLayout, navigateTo, useRoute, useRouter } from '#app/composables/router'; +export { isPrerendered, loadPayload, preloadPayload, definePayloadReducer, definePayloadReviver } from '#app/composables/payload'; +export { getAppManifest, getRouteRules } from '#app/composables/manifest'; +export { reloadNuxtApp } from '#app/composables/chunk'; +export { useRequestURL } from '#app/composables/url'; +export { onBeforeRouteLeave, onBeforeRouteUpdate, useLink } from '#vue-router'; +export { withCtx, withDirectives, withKeys, withMemo, withModifiers, withScopeId, onActivated, onBeforeMount, onBeforeUnmount, onBeforeUpdate, onDeactivated, onErrorCaptured, onMounted, onRenderTracked, onRenderTriggered, onServerPrefetch, onUnmounted, onUpdated, computed, customRef, isProxy, isReactive, isReadonly, isRef, markRaw, proxyRefs, reactive, readonly, ref, shallowReactive, shallowReadonly, shallowRef, toRaw, toRef, toRefs, triggerRef, unref, watch, watchEffect, watchPostEffect, watchSyncEffect, isShallow, effect, effectScope, getCurrentScope, onScopeDispose, defineComponent, defineAsyncComponent, resolveComponent, getCurrentInstance, h, inject, hasInjectionContext, nextTick, provide, defineModel, defineOptions, defineSlots, mergeModels, toValue, useModel, useAttrs, useCssModule, useCssVars, useSlots, useTransitionState, Component, ComponentPublicInstance, ComputedRef, ExtractPropTypes, ExtractPublicPropTypes, InjectionKey, PropType, Ref, MaybeRef, MaybeRefOrGetter, VNode } from 'vue'; +export { injectHead, useHead, useSeoMeta, useHeadSafe, useServerHead, useServerSeoMeta, useServerHeadSafe } from '@unhead/vue'; +export { definePageMeta } from '../../../../../node_modules/nuxt/dist/pages/runtime/composables'; \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/nuxt.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/nuxt.d.ts new file mode 100644 index 000000000..0269dec0e --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/nuxt.d.ts @@ -0,0 +1,21 @@ +// Generated by nuxi +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// + +export {} diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/schema/nuxt.schema.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/schema/nuxt.schema.d.ts new file mode 100644 index 000000000..d9d266ce5 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/schema/nuxt.schema.d.ts @@ -0,0 +1,17 @@ +export interface NuxtCustomSchema { + +} +export type CustomAppConfig = Exclude +type _CustomAppConfig = CustomAppConfig + +declare module '@nuxt/schema' { + interface NuxtConfig extends Omit {} + interface NuxtOptions extends Omit {} + interface CustomAppConfig extends _CustomAppConfig {} +} + +declare module 'nuxt/schema' { + interface NuxtConfig extends Omit {} + interface NuxtOptions extends Omit {} + interface CustomAppConfig extends _CustomAppConfig {} +} diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/schema/nuxt.schema.json b/packages/vue/examples/with-nuxt-typescript/.nuxt/schema/nuxt.schema.json new file mode 100644 index 000000000..034ff697e --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/schema/nuxt.schema.json @@ -0,0 +1,3 @@ +{ + "id": "#" +} \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/tsconfig.json b/packages/vue/examples/with-nuxt-typescript/.nuxt/tsconfig.json new file mode 100644 index 000000000..f09a9a8eb --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/tsconfig.json @@ -0,0 +1,100 @@ +// Generated by nuxi +{ + "compilerOptions": { + "forceConsistentCasingInFileNames": true, + "jsx": "preserve", + "jsxImportSource": "vue", + "target": "ESNext", + "module": "ESNext", + "moduleResolution": "Node", + "skipLibCheck": true, + "isolatedModules": true, + "useDefineForClassFields": true, + "strict": true, + "noImplicitThis": true, + "esModuleInterop": true, + "types": [], + "verbatimModuleSyntax": true, + "allowJs": true, + "noEmit": true, + "resolveJsonModule": true, + "allowSyntheticDefaultImports": true, + "paths": { + "~": [ + ".." + ], + "~/*": [ + "../*" + ], + "@": [ + ".." + ], + "@/*": [ + "../*" + ], + "~~": [ + ".." + ], + "~~/*": [ + "../*" + ], + "@@": [ + ".." + ], + "@@/*": [ + "../*" + ], + "assets": [ + "../assets" + ], + "assets/*": [ + "../assets/*" + ], + "public": [ + "../public" + ], + "#app": [ + "../../../../../node_modules/nuxt/dist/app" + ], + "#app/*": [ + "../../../../../node_modules/nuxt/dist/app/*" + ], + "vue-demi": [ + "../../../../../node_modules/nuxt/dist/app/compat/vue-demi" + ], + "#vue-router": [ + "./vue-router-stub" + ], + "#imports": [ + "./imports" + ], + "#build": [ + "." + ], + "#build/*": [ + "./*" + ], + "#components": [ + "./components" + ] + } + }, + "include": [ + "./nuxt.d.ts", + "../**/*", + "../../../../../node_modules/@nuxtjs/emotion/runtime", + "../../../../../node_modules/@nuxt/devtools/runtime", + "..", + "../../../../../node_modules/nuxt/dist/app", + "../../../../../node_modules/nuxt/dist/app/compat/vue-demi" + ], + "exclude": [ + "../node_modules", + "../../../../../node_modules", + "../../../../../node_modules/nuxt/node_modules", + "../../../../../node_modules/@nuxtjs/emotion/runtime/server", + "../../../../../node_modules/@nuxt/devtools/runtime/server", + "../dist", + "../.vercel/output" + ] +} \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/tsconfig.server.json b/packages/vue/examples/with-nuxt-typescript/.nuxt/tsconfig.server.json new file mode 100644 index 000000000..3c33057ba --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/tsconfig.server.json @@ -0,0 +1,70 @@ +{ + "compilerOptions": { + "forceConsistentCasingInFileNames": true, + "strict": true, + "target": "ESNext", + "module": "ESNext", + "moduleResolution": "Node", + "allowJs": true, + "resolveJsonModule": true, + "jsx": "preserve", + "allowSyntheticDefaultImports": true, + "jsxFactory": "h", + "jsxFragmentFactory": "Fragment", + "paths": { + "#imports": [ + "./types/nitro-imports" + ], + "#paths": [ + "../../../../../node_modules/nuxt/dist/core/runtime/nitro/paths" + ], + "~": [ + "./.." + ], + "~/*": [ + "../*" + ], + "@": [ + "./.." + ], + "@/*": [ + "../*" + ], + "~~": [ + "./.." + ], + "~~/*": [ + "../*" + ], + "@@": [ + "./.." + ], + "@@/*": [ + "../*" + ], + "assets": [ + "../assets" + ], + "assets/*": [ + "../assets/*" + ], + "public": [ + "../public" + ] + } + }, + "include": [ + "./types/nitro-nuxt.d.ts", + "../../../../../node_modules/@nuxtjs/emotion/runtime/server", + "../../../../../node_modules/@nuxt/devtools/runtime/server", + "./types/nitro.d.ts", + "../**/*", + "../server/**/*" + ], + "exclude": [ + "../node_modules", + "../../../../../node_modules", + "../../../../../node_modules/nuxt/node_modules", + "../dist" + ] +} \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/app.config.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/app.config.d.ts new file mode 100644 index 000000000..5725e3bf9 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/app.config.d.ts @@ -0,0 +1,33 @@ + +import type { CustomAppConfig } from 'nuxt/schema' +import type { Defu } from 'defu' + + +declare const inlineConfig = { + "nuxt": { + "buildId": "d36fc3fc-868f-462a-b7af-cc6d9457242a" + } +} +type ResolvedAppConfig = Defu +type IsAny = 0 extends 1 & T ? true : false + +type MergedAppConfig, Custom extends Record> = { + [K in keyof (Resolved & Custom)]: K extends keyof Custom + ? unknown extends Custom[K] + ? Resolved[K] + : IsAny extends true + ? Resolved[K] + : Custom[K] extends Record + ? Resolved[K] extends Record + ? MergedAppConfig + : Exclude + : Exclude + : Resolved[K] +} + +declare module 'nuxt/schema' { + interface AppConfig extends MergedAppConfig { } +} +declare module '@nuxt/schema' { + interface AppConfig extends MergedAppConfig { } +} diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/imports.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/imports.d.ts new file mode 100644 index 000000000..1f7e105b7 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/imports.d.ts @@ -0,0 +1,412 @@ +// Generated by auto imports +export {} +declare global { + const abortNavigation: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/router')['abortNavigation'] + const addRouteMiddleware: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/router')['addRouteMiddleware'] + const cancelIdleCallback: typeof import('../../../../../../node_modules/nuxt/dist/app/compat/idle-callback')['cancelIdleCallback'] + const clearError: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/error')['clearError'] + const clearNuxtData: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/asyncData')['clearNuxtData'] + const clearNuxtState: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/state')['clearNuxtState'] + const computed: typeof import('../../../../../../node_modules/vue')['computed'] + const createError: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/error')['createError'] + const customRef: typeof import('../../../../../../node_modules/vue')['customRef'] + const defineAppConfig: typeof import('../../../../../../node_modules/nuxt/dist/app/nuxt')['defineAppConfig'] + const defineAsyncComponent: typeof import('../../../../../../node_modules/vue')['defineAsyncComponent'] + const defineComponent: typeof import('../../../../../../node_modules/vue')['defineComponent'] + const defineModel: typeof import('../../../../../../node_modules/vue')['defineModel'] + const defineNuxtComponent: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/component')['defineNuxtComponent'] + const defineNuxtLink: typeof import('../../../../../../node_modules/nuxt/dist/app/components/nuxt-link')['defineNuxtLink'] + const defineNuxtPlugin: typeof import('../../../../../../node_modules/nuxt/dist/app/nuxt')['defineNuxtPlugin'] + const defineNuxtRouteMiddleware: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/router')['defineNuxtRouteMiddleware'] + const defineOptions: typeof import('../../../../../../node_modules/vue')['defineOptions'] + const definePageMeta: typeof import('../../../../../../node_modules/nuxt/dist/pages/runtime/composables')['definePageMeta'] + const definePayloadPlugin: typeof import('../../../../../../node_modules/nuxt/dist/app/nuxt')['definePayloadPlugin'] + const definePayloadReducer: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/payload')['definePayloadReducer'] + const definePayloadReviver: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/payload')['definePayloadReviver'] + const defineSlots: typeof import('../../../../../../node_modules/vue')['defineSlots'] + const effect: typeof import('../../../../../../node_modules/vue')['effect'] + const effectScope: typeof import('../../../../../../node_modules/vue')['effectScope'] + const getAppManifest: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/manifest')['getAppManifest'] + const getCurrentInstance: typeof import('../../../../../../node_modules/vue')['getCurrentInstance'] + const getCurrentScope: typeof import('../../../../../../node_modules/vue')['getCurrentScope'] + const getRouteRules: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/manifest')['getRouteRules'] + const h: typeof import('../../../../../../node_modules/vue')['h'] + const hasInjectionContext: typeof import('../../../../../../node_modules/vue')['hasInjectionContext'] + const inject: typeof import('../../../../../../node_modules/vue')['inject'] + const injectHead: typeof import('../../../../../../node_modules/@unhead/vue')['injectHead'] + const isNuxtError: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/error')['isNuxtError'] + const isPrerendered: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/payload')['isPrerendered'] + const isProxy: typeof import('../../../../../../node_modules/vue')['isProxy'] + const isReactive: typeof import('../../../../../../node_modules/vue')['isReactive'] + const isReadonly: typeof import('../../../../../../node_modules/vue')['isReadonly'] + const isRef: typeof import('../../../../../../node_modules/vue')['isRef'] + const isShallow: typeof import('../../../../../../node_modules/vue')['isShallow'] + const isVue2: typeof import('../../../../../../node_modules/nuxt/dist/app/compat/vue-demi')['isVue2'] + const isVue3: typeof import('../../../../../../node_modules/nuxt/dist/app/compat/vue-demi')['isVue3'] + const loadPayload: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/payload')['loadPayload'] + const markRaw: typeof import('../../../../../../node_modules/vue')['markRaw'] + const mergeModels: typeof import('../../../../../../node_modules/vue')['mergeModels'] + const navigateTo: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/router')['navigateTo'] + const nextTick: typeof import('../../../../../../node_modules/vue')['nextTick'] + const onActivated: typeof import('../../../../../../node_modules/vue')['onActivated'] + const onBeforeMount: typeof import('../../../../../../node_modules/vue')['onBeforeMount'] + const onBeforeRouteLeave: typeof import('../vue-router-stub')['onBeforeRouteLeave'] + const onBeforeRouteUpdate: typeof import('../vue-router-stub')['onBeforeRouteUpdate'] + const onBeforeUnmount: typeof import('../../../../../../node_modules/vue')['onBeforeUnmount'] + const onBeforeUpdate: typeof import('../../../../../../node_modules/vue')['onBeforeUpdate'] + const onDeactivated: typeof import('../../../../../../node_modules/vue')['onDeactivated'] + const onErrorCaptured: typeof import('../../../../../../node_modules/vue')['onErrorCaptured'] + const onMounted: typeof import('../../../../../../node_modules/vue')['onMounted'] + const onNuxtReady: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/ready')['onNuxtReady'] + const onRenderTracked: typeof import('../../../../../../node_modules/vue')['onRenderTracked'] + const onRenderTriggered: typeof import('../../../../../../node_modules/vue')['onRenderTriggered'] + const onScopeDispose: typeof import('../../../../../../node_modules/vue')['onScopeDispose'] + const onServerPrefetch: typeof import('../../../../../../node_modules/vue')['onServerPrefetch'] + const onUnmounted: typeof import('../../../../../../node_modules/vue')['onUnmounted'] + const onUpdated: typeof import('../../../../../../node_modules/vue')['onUpdated'] + const prefetchComponents: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/preload')['prefetchComponents'] + const preloadComponents: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/preload')['preloadComponents'] + const preloadPayload: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/payload')['preloadPayload'] + const preloadRouteComponents: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/preload')['preloadRouteComponents'] + const prerenderRoutes: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/ssr')['prerenderRoutes'] + const provide: typeof import('../../../../../../node_modules/vue')['provide'] + const proxyRefs: typeof import('../../../../../../node_modules/vue')['proxyRefs'] + const reactive: typeof import('../../../../../../node_modules/vue')['reactive'] + const readonly: typeof import('../../../../../../node_modules/vue')['readonly'] + const ref: typeof import('../../../../../../node_modules/vue')['ref'] + const refreshNuxtData: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/asyncData')['refreshNuxtData'] + const reloadNuxtApp: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/chunk')['reloadNuxtApp'] + const requestIdleCallback: typeof import('../../../../../../node_modules/nuxt/dist/app/compat/idle-callback')['requestIdleCallback'] + const resolveComponent: typeof import('../../../../../../node_modules/vue')['resolveComponent'] + const setPageLayout: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/router')['setPageLayout'] + const setResponseStatus: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/ssr')['setResponseStatus'] + const shallowReactive: typeof import('../../../../../../node_modules/vue')['shallowReactive'] + const shallowReadonly: typeof import('../../../../../../node_modules/vue')['shallowReadonly'] + const shallowRef: typeof import('../../../../../../node_modules/vue')['shallowRef'] + const showError: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/error')['showError'] + const toRaw: typeof import('../../../../../../node_modules/vue')['toRaw'] + const toRef: typeof import('../../../../../../node_modules/vue')['toRef'] + const toRefs: typeof import('../../../../../../node_modules/vue')['toRefs'] + const toValue: typeof import('../../../../../../node_modules/vue')['toValue'] + const triggerRef: typeof import('../../../../../../node_modules/vue')['triggerRef'] + const unref: typeof import('../../../../../../node_modules/vue')['unref'] + const updateAppConfig: typeof import('../../../../../../node_modules/nuxt/dist/app/config')['updateAppConfig'] + const useAppConfig: typeof import('../../../../../../node_modules/nuxt/dist/app/config')['useAppConfig'] + const useAsyncData: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/asyncData')['useAsyncData'] + const useAttrs: typeof import('../../../../../../node_modules/vue')['useAttrs'] + const useCookie: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/cookie')['useCookie'] + const useCssModule: typeof import('../../../../../../node_modules/vue')['useCssModule'] + const useCssVars: typeof import('../../../../../../node_modules/vue')['useCssVars'] + const useError: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/error')['useError'] + const useFetch: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/fetch')['useFetch'] + const useHead: typeof import('../../../../../../node_modules/@unhead/vue')['useHead'] + const useHeadSafe: typeof import('../../../../../../node_modules/@unhead/vue')['useHeadSafe'] + const useHydration: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/hydrate')['useHydration'] + const useLazyAsyncData: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/asyncData')['useLazyAsyncData'] + const useLazyFetch: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/fetch')['useLazyFetch'] + const useLink: typeof import('../vue-router-stub')['useLink'] + const useModel: typeof import('../../../../../../node_modules/vue')['useModel'] + const useNuxtApp: typeof import('../../../../../../node_modules/nuxt/dist/app/nuxt')['useNuxtApp'] + const useNuxtData: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/asyncData')['useNuxtData'] + const useRequestEvent: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/ssr')['useRequestEvent'] + const useRequestFetch: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/ssr')['useRequestFetch'] + const useRequestHeaders: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/ssr')['useRequestHeaders'] + const useRequestURL: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/url')['useRequestURL'] + const useRoute: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/router')['useRoute'] + const useRouter: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/router')['useRouter'] + const useRuntimeConfig: typeof import('../../../../../../node_modules/nuxt/dist/app/nuxt')['useRuntimeConfig'] + const useSeoMeta: typeof import('../../../../../../node_modules/@unhead/vue')['useSeoMeta'] + const useServerHead: typeof import('../../../../../../node_modules/@unhead/vue')['useServerHead'] + const useServerHeadSafe: typeof import('../../../../../../node_modules/@unhead/vue')['useServerHeadSafe'] + const useServerSeoMeta: typeof import('../../../../../../node_modules/@unhead/vue')['useServerSeoMeta'] + const useSlots: typeof import('../../../../../../node_modules/vue')['useSlots'] + const useState: typeof import('../../../../../../node_modules/nuxt/dist/app/composables/state')['useState'] + const useTransitionState: typeof import('../../../../../../node_modules/vue')['useTransitionState'] + const watch: typeof import('../../../../../../node_modules/vue')['watch'] + const watchEffect: typeof import('../../../../../../node_modules/vue')['watchEffect'] + const watchPostEffect: typeof import('../../../../../../node_modules/vue')['watchPostEffect'] + const watchSyncEffect: typeof import('../../../../../../node_modules/vue')['watchSyncEffect'] + const withCtx: typeof import('../../../../../../node_modules/vue')['withCtx'] + const withDirectives: typeof import('../../../../../../node_modules/vue')['withDirectives'] + const withKeys: typeof import('../../../../../../node_modules/vue')['withKeys'] + const withMemo: typeof import('../../../../../../node_modules/vue')['withMemo'] + const withModifiers: typeof import('../../../../../../node_modules/vue')['withModifiers'] + const withScopeId: typeof import('../../../../../../node_modules/vue')['withScopeId'] +} +// for type re-export +declare global { + // @ts-ignore + export type { Component, ComponentPublicInstance, ComputedRef, ExtractPropTypes, ExtractPublicPropTypes, InjectionKey, PropType, Ref, MaybeRef, MaybeRefOrGetter, VNode } from '../../../../../../node_modules/vue' +} +// for vue template auto import +import { UnwrapRef } from 'vue' +declare module 'vue' { + interface ComponentCustomProperties { + readonly abortNavigation: UnwrapRef + readonly addRouteMiddleware: UnwrapRef + readonly cancelIdleCallback: UnwrapRef + readonly clearError: UnwrapRef + readonly clearNuxtData: UnwrapRef + readonly clearNuxtState: UnwrapRef + readonly computed: UnwrapRef + readonly createError: UnwrapRef + readonly customRef: UnwrapRef + readonly defineAppConfig: UnwrapRef + readonly defineAsyncComponent: UnwrapRef + readonly defineComponent: UnwrapRef + readonly defineModel: UnwrapRef + readonly defineNuxtComponent: UnwrapRef + readonly defineNuxtLink: UnwrapRef + readonly defineNuxtPlugin: UnwrapRef + readonly defineNuxtRouteMiddleware: UnwrapRef + readonly defineOptions: UnwrapRef + readonly definePageMeta: UnwrapRef + readonly definePayloadPlugin: UnwrapRef + readonly definePayloadReducer: UnwrapRef + readonly definePayloadReviver: UnwrapRef + readonly defineSlots: UnwrapRef + readonly effect: UnwrapRef + readonly effectScope: UnwrapRef + readonly getAppManifest: UnwrapRef + readonly getCurrentInstance: UnwrapRef + readonly getCurrentScope: UnwrapRef + readonly getRouteRules: UnwrapRef + readonly h: UnwrapRef + readonly hasInjectionContext: UnwrapRef + readonly inject: UnwrapRef + readonly injectHead: UnwrapRef + readonly isNuxtError: UnwrapRef + readonly isPrerendered: UnwrapRef + readonly isProxy: UnwrapRef + readonly isReactive: UnwrapRef + readonly isReadonly: UnwrapRef + readonly isRef: UnwrapRef + readonly isShallow: UnwrapRef + readonly isVue2: UnwrapRef + readonly isVue3: UnwrapRef + readonly loadPayload: UnwrapRef + readonly markRaw: UnwrapRef + readonly mergeModels: UnwrapRef + readonly navigateTo: UnwrapRef + readonly nextTick: UnwrapRef + readonly onActivated: UnwrapRef + readonly onBeforeMount: UnwrapRef + readonly onBeforeRouteLeave: UnwrapRef + readonly onBeforeRouteUpdate: UnwrapRef + readonly onBeforeUnmount: UnwrapRef + readonly onBeforeUpdate: UnwrapRef + readonly onDeactivated: UnwrapRef + readonly onErrorCaptured: UnwrapRef + readonly onMounted: UnwrapRef + readonly onNuxtReady: UnwrapRef + readonly onRenderTracked: UnwrapRef + readonly onRenderTriggered: UnwrapRef + readonly onScopeDispose: UnwrapRef + readonly onServerPrefetch: UnwrapRef + readonly onUnmounted: UnwrapRef + readonly onUpdated: UnwrapRef + readonly prefetchComponents: UnwrapRef + readonly preloadComponents: UnwrapRef + readonly preloadPayload: UnwrapRef + readonly preloadRouteComponents: UnwrapRef + readonly prerenderRoutes: UnwrapRef + readonly provide: UnwrapRef + readonly proxyRefs: UnwrapRef + readonly reactive: UnwrapRef + readonly readonly: UnwrapRef + readonly ref: UnwrapRef + readonly refreshNuxtData: UnwrapRef + readonly reloadNuxtApp: UnwrapRef + readonly requestIdleCallback: UnwrapRef + readonly resolveComponent: UnwrapRef + readonly setPageLayout: UnwrapRef + readonly setResponseStatus: UnwrapRef + readonly shallowReactive: UnwrapRef + readonly shallowReadonly: UnwrapRef + readonly shallowRef: UnwrapRef + readonly showError: UnwrapRef + readonly toRaw: UnwrapRef + readonly toRef: UnwrapRef + readonly toRefs: UnwrapRef + readonly toValue: UnwrapRef + readonly triggerRef: UnwrapRef + readonly unref: UnwrapRef + readonly updateAppConfig: UnwrapRef + readonly useAppConfig: UnwrapRef + readonly useAsyncData: UnwrapRef + readonly useAttrs: UnwrapRef + readonly useCookie: UnwrapRef + readonly useCssModule: UnwrapRef + readonly useCssVars: UnwrapRef + readonly useError: UnwrapRef + readonly useFetch: UnwrapRef + readonly useHead: UnwrapRef + readonly useHeadSafe: UnwrapRef + readonly useHydration: UnwrapRef + readonly useLazyAsyncData: UnwrapRef + readonly useLazyFetch: UnwrapRef + readonly useLink: UnwrapRef + readonly useModel: UnwrapRef + readonly useNuxtApp: UnwrapRef + readonly useNuxtData: UnwrapRef + readonly useRequestEvent: UnwrapRef + readonly useRequestFetch: UnwrapRef + readonly useRequestHeaders: UnwrapRef + readonly useRequestURL: UnwrapRef + readonly useRoute: UnwrapRef + readonly useRouter: UnwrapRef + readonly useRuntimeConfig: UnwrapRef + readonly useSeoMeta: UnwrapRef + readonly useServerHead: UnwrapRef + readonly useServerHeadSafe: UnwrapRef + readonly useServerSeoMeta: UnwrapRef + readonly useSlots: UnwrapRef + readonly useState: UnwrapRef + readonly useTransitionState: UnwrapRef + readonly watch: UnwrapRef + readonly watchEffect: UnwrapRef + readonly watchPostEffect: UnwrapRef + readonly watchSyncEffect: UnwrapRef + readonly withCtx: UnwrapRef + readonly withDirectives: UnwrapRef + readonly withKeys: UnwrapRef + readonly withMemo: UnwrapRef + readonly withModifiers: UnwrapRef + readonly withScopeId: UnwrapRef + } +} +declare module '@vue/runtime-core' { + interface ComponentCustomProperties { + readonly abortNavigation: UnwrapRef + readonly addRouteMiddleware: UnwrapRef + readonly cancelIdleCallback: UnwrapRef + readonly clearError: UnwrapRef + readonly clearNuxtData: UnwrapRef + readonly clearNuxtState: UnwrapRef + readonly computed: UnwrapRef + readonly createError: UnwrapRef + readonly customRef: UnwrapRef + readonly defineAppConfig: UnwrapRef + readonly defineAsyncComponent: UnwrapRef + readonly defineComponent: UnwrapRef + readonly defineModel: UnwrapRef + readonly defineNuxtComponent: UnwrapRef + readonly defineNuxtLink: UnwrapRef + readonly defineNuxtPlugin: UnwrapRef + readonly defineNuxtRouteMiddleware: UnwrapRef + readonly defineOptions: UnwrapRef + readonly definePageMeta: UnwrapRef + readonly definePayloadPlugin: UnwrapRef + readonly definePayloadReducer: UnwrapRef + readonly definePayloadReviver: UnwrapRef + readonly defineSlots: UnwrapRef + readonly effect: UnwrapRef + readonly effectScope: UnwrapRef + readonly getAppManifest: UnwrapRef + readonly getCurrentInstance: UnwrapRef + readonly getCurrentScope: UnwrapRef + readonly getRouteRules: UnwrapRef + readonly h: UnwrapRef + readonly hasInjectionContext: UnwrapRef + readonly inject: UnwrapRef + readonly injectHead: UnwrapRef + readonly isNuxtError: UnwrapRef + readonly isPrerendered: UnwrapRef + readonly isProxy: UnwrapRef + readonly isReactive: UnwrapRef + readonly isReadonly: UnwrapRef + readonly isRef: UnwrapRef + readonly isShallow: UnwrapRef + readonly isVue2: UnwrapRef + readonly isVue3: UnwrapRef + readonly loadPayload: UnwrapRef + readonly markRaw: UnwrapRef + readonly mergeModels: UnwrapRef + readonly navigateTo: UnwrapRef + readonly nextTick: UnwrapRef + readonly onActivated: UnwrapRef + readonly onBeforeMount: UnwrapRef + readonly onBeforeRouteLeave: UnwrapRef + readonly onBeforeRouteUpdate: UnwrapRef + readonly onBeforeUnmount: UnwrapRef + readonly onBeforeUpdate: UnwrapRef + readonly onDeactivated: UnwrapRef + readonly onErrorCaptured: UnwrapRef + readonly onMounted: UnwrapRef + readonly onNuxtReady: UnwrapRef + readonly onRenderTracked: UnwrapRef + readonly onRenderTriggered: UnwrapRef + readonly onScopeDispose: UnwrapRef + readonly onServerPrefetch: UnwrapRef + readonly onUnmounted: UnwrapRef + readonly onUpdated: UnwrapRef + readonly prefetchComponents: UnwrapRef + readonly preloadComponents: UnwrapRef + readonly preloadPayload: UnwrapRef + readonly preloadRouteComponents: UnwrapRef + readonly prerenderRoutes: UnwrapRef + readonly provide: UnwrapRef + readonly proxyRefs: UnwrapRef + readonly reactive: UnwrapRef + readonly readonly: UnwrapRef + readonly ref: UnwrapRef + readonly refreshNuxtData: UnwrapRef + readonly reloadNuxtApp: UnwrapRef + readonly requestIdleCallback: UnwrapRef + readonly resolveComponent: UnwrapRef + readonly setPageLayout: UnwrapRef + readonly setResponseStatus: UnwrapRef + readonly shallowReactive: UnwrapRef + readonly shallowReadonly: UnwrapRef + readonly shallowRef: UnwrapRef + readonly showError: UnwrapRef + readonly toRaw: UnwrapRef + readonly toRef: UnwrapRef + readonly toRefs: UnwrapRef + readonly toValue: UnwrapRef + readonly triggerRef: UnwrapRef + readonly unref: UnwrapRef + readonly updateAppConfig: UnwrapRef + readonly useAppConfig: UnwrapRef + readonly useAsyncData: UnwrapRef + readonly useAttrs: UnwrapRef + readonly useCookie: UnwrapRef + readonly useCssModule: UnwrapRef + readonly useCssVars: UnwrapRef + readonly useError: UnwrapRef + readonly useFetch: UnwrapRef + readonly useHead: UnwrapRef + readonly useHeadSafe: UnwrapRef + readonly useHydration: UnwrapRef + readonly useLazyAsyncData: UnwrapRef + readonly useLazyFetch: UnwrapRef + readonly useLink: UnwrapRef + readonly useModel: UnwrapRef + readonly useNuxtApp: UnwrapRef + readonly useNuxtData: UnwrapRef + readonly useRequestEvent: UnwrapRef + readonly useRequestFetch: UnwrapRef + readonly useRequestHeaders: UnwrapRef + readonly useRequestURL: UnwrapRef + readonly useRoute: UnwrapRef + readonly useRouter: UnwrapRef + readonly useRuntimeConfig: UnwrapRef + readonly useSeoMeta: UnwrapRef + readonly useServerHead: UnwrapRef + readonly useServerHeadSafe: UnwrapRef + readonly useServerSeoMeta: UnwrapRef + readonly useSlots: UnwrapRef + readonly useState: UnwrapRef + readonly useTransitionState: UnwrapRef + readonly watch: UnwrapRef + readonly watchEffect: UnwrapRef + readonly watchPostEffect: UnwrapRef + readonly watchSyncEffect: UnwrapRef + readonly withCtx: UnwrapRef + readonly withDirectives: UnwrapRef + readonly withKeys: UnwrapRef + readonly withMemo: UnwrapRef + readonly withModifiers: UnwrapRef + readonly withScopeId: UnwrapRef + } +} diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/layouts.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/layouts.d.ts new file mode 100644 index 000000000..6379a0967 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/layouts.d.ts @@ -0,0 +1,7 @@ +import { ComputedRef, MaybeRef } from 'vue' +export type LayoutKey = string +declare module "../../../../../../node_modules/nuxt/dist/pages/runtime/composables" { + interface PageMeta { + layout?: MaybeRef | ComputedRef + } +} \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/middleware.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/middleware.d.ts new file mode 100644 index 000000000..2492baa33 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/middleware.d.ts @@ -0,0 +1,7 @@ +import type { NavigationGuard } from 'vue-router' +export type MiddlewareKey = string +declare module "../../../../../../node_modules/nuxt/dist/pages/runtime/composables" { + interface PageMeta { + middleware?: MiddlewareKey | NavigationGuard | Array + } +} \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-config.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-config.d.ts new file mode 100644 index 000000000..29f793980 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-config.d.ts @@ -0,0 +1,14 @@ +// Generated by nitro + +// App Config +import type { Defu } from 'defu' + + + +type UserAppConfig = Defu<{}, []> + +declare module 'nitropack' { + interface AppConfig extends UserAppConfig {} +} + +export {} \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-imports.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-imports.d.ts new file mode 100644 index 000000000..a913bb689 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-imports.d.ts @@ -0,0 +1,121 @@ +declare global { + const __buildAssetsURL: typeof import('../../../../../../node_modules/nuxt/dist/core/runtime/nitro/paths')['buildAssetsURL'] + const __publicAssetsURL: typeof import('../../../../../../node_modules/nuxt/dist/core/runtime/nitro/paths')['publicAssetsURL'] + const appendCorsHeaders: typeof import('../../../../../../node_modules/h3')['appendCorsHeaders'] + const appendCorsPreflightHeaders: typeof import('../../../../../../node_modules/h3')['appendCorsPreflightHeaders'] + const appendHeader: typeof import('../../../../../../node_modules/h3')['appendHeader'] + const appendHeaders: typeof import('../../../../../../node_modules/h3')['appendHeaders'] + const appendResponseHeader: typeof import('../../../../../../node_modules/h3')['appendResponseHeader'] + const appendResponseHeaders: typeof import('../../../../../../node_modules/h3')['appendResponseHeaders'] + const assertMethod: typeof import('../../../../../../node_modules/h3')['assertMethod'] + const cachedEventHandler: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['cachedEventHandler'] + const cachedFunction: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['cachedFunction'] + const callNodeListener: typeof import('../../../../../../node_modules/h3')['callNodeListener'] + const clearResponseHeaders: typeof import('../../../../../../node_modules/h3')['clearResponseHeaders'] + const clearSession: typeof import('../../../../../../node_modules/h3')['clearSession'] + const createApp: typeof import('../../../../../../node_modules/h3')['createApp'] + const createAppEventHandler: typeof import('../../../../../../node_modules/h3')['createAppEventHandler'] + const createError: typeof import('../../../../../../node_modules/h3')['createError'] + const createEvent: typeof import('../../../../../../node_modules/h3')['createEvent'] + const createRouter: typeof import('../../../../../../node_modules/h3')['createRouter'] + const defaultContentType: typeof import('../../../../../../node_modules/h3')['defaultContentType'] + const defineAppConfig: typeof import('../../../../../../node_modules/nuxt/dist/core/runtime/nitro/config')['defineAppConfig'] + const defineCachedEventHandler: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['defineCachedEventHandler'] + const defineCachedFunction: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['defineCachedFunction'] + const defineEventHandler: typeof import('../../../../../../node_modules/h3')['defineEventHandler'] + const defineLazyEventHandler: typeof import('../../../../../../node_modules/h3')['defineLazyEventHandler'] + const defineNitroPlugin: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['defineNitroPlugin'] + const defineNodeListener: typeof import('../../../../../../node_modules/h3')['defineNodeListener'] + const defineNodeMiddleware: typeof import('../../../../../../node_modules/h3')['defineNodeMiddleware'] + const defineRenderHandler: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['defineRenderHandler'] + const defineRequestMiddleware: typeof import('../../../../../../node_modules/h3')['defineRequestMiddleware'] + const defineResponseMiddleware: typeof import('../../../../../../node_modules/h3')['defineResponseMiddleware'] + const deleteCookie: typeof import('../../../../../../node_modules/h3')['deleteCookie'] + const dynamicEventHandler: typeof import('../../../../../../node_modules/h3')['dynamicEventHandler'] + const eventHandler: typeof import('../../../../../../node_modules/h3')['eventHandler'] + const fetchWithEvent: typeof import('../../../../../../node_modules/h3')['fetchWithEvent'] + const fromNodeMiddleware: typeof import('../../../../../../node_modules/h3')['fromNodeMiddleware'] + const fromPlainHandler: typeof import('../../../../../../node_modules/h3')['fromPlainHandler'] + const fromWebHandler: typeof import('../../../../../../node_modules/h3')['fromWebHandler'] + const getCookie: typeof import('../../../../../../node_modules/h3')['getCookie'] + const getHeader: typeof import('../../../../../../node_modules/h3')['getHeader'] + const getHeaders: typeof import('../../../../../../node_modules/h3')['getHeaders'] + const getMethod: typeof import('../../../../../../node_modules/h3')['getMethod'] + const getProxyRequestHeaders: typeof import('../../../../../../node_modules/h3')['getProxyRequestHeaders'] + const getQuery: typeof import('../../../../../../node_modules/h3')['getQuery'] + const getRequestHeader: typeof import('../../../../../../node_modules/h3')['getRequestHeader'] + const getRequestHeaders: typeof import('../../../../../../node_modules/h3')['getRequestHeaders'] + const getRequestHost: typeof import('../../../../../../node_modules/h3')['getRequestHost'] + const getRequestIP: typeof import('../../../../../../node_modules/h3')['getRequestIP'] + const getRequestPath: typeof import('../../../../../../node_modules/h3')['getRequestPath'] + const getRequestProtocol: typeof import('../../../../../../node_modules/h3')['getRequestProtocol'] + const getRequestURL: typeof import('../../../../../../node_modules/h3')['getRequestURL'] + const getRequestWebStream: typeof import('../../../../../../node_modules/h3')['getRequestWebStream'] + const getResponseHeader: typeof import('../../../../../../node_modules/h3')['getResponseHeader'] + const getResponseHeaders: typeof import('../../../../../../node_modules/h3')['getResponseHeaders'] + const getResponseStatus: typeof import('../../../../../../node_modules/h3')['getResponseStatus'] + const getResponseStatusText: typeof import('../../../../../../node_modules/h3')['getResponseStatusText'] + const getRouteRules: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['getRouteRules'] + const getRouterParam: typeof import('../../../../../../node_modules/h3')['getRouterParam'] + const getRouterParams: typeof import('../../../../../../node_modules/h3')['getRouterParams'] + const getSession: typeof import('../../../../../../node_modules/h3')['getSession'] + const getValidatedQuery: typeof import('../../../../../../node_modules/h3')['getValidatedQuery'] + const handleCacheHeaders: typeof import('../../../../../../node_modules/h3')['handleCacheHeaders'] + const handleCors: typeof import('../../../../../../node_modules/h3')['handleCors'] + const isCorsOriginAllowed: typeof import('../../../../../../node_modules/h3')['isCorsOriginAllowed'] + const isError: typeof import('../../../../../../node_modules/h3')['isError'] + const isEvent: typeof import('../../../../../../node_modules/h3')['isEvent'] + const isEventHandler: typeof import('../../../../../../node_modules/h3')['isEventHandler'] + const isMethod: typeof import('../../../../../../node_modules/h3')['isMethod'] + const isPreflightRequest: typeof import('../../../../../../node_modules/h3')['isPreflightRequest'] + const isStream: typeof import('../../../../../../node_modules/h3')['isStream'] + const isWebResponse: typeof import('../../../../../../node_modules/h3')['isWebResponse'] + const lazyEventHandler: typeof import('../../../../../../node_modules/h3')['lazyEventHandler'] + const nitroPlugin: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['nitroPlugin'] + const parseCookies: typeof import('../../../../../../node_modules/h3')['parseCookies'] + const promisifyNodeListener: typeof import('../../../../../../node_modules/h3')['promisifyNodeListener'] + const proxyRequest: typeof import('../../../../../../node_modules/h3')['proxyRequest'] + const readBody: typeof import('../../../../../../node_modules/h3')['readBody'] + const readFormData: typeof import('../../../../../../node_modules/h3')['readFormData'] + const readMultipartFormData: typeof import('../../../../../../node_modules/h3')['readMultipartFormData'] + const readRawBody: typeof import('../../../../../../node_modules/h3')['readRawBody'] + const readValidatedBody: typeof import('../../../../../../node_modules/h3')['readValidatedBody'] + const removeResponseHeader: typeof import('../../../../../../node_modules/h3')['removeResponseHeader'] + const sanitizeStatusCode: typeof import('../../../../../../node_modules/h3')['sanitizeStatusCode'] + const sanitizeStatusMessage: typeof import('../../../../../../node_modules/h3')['sanitizeStatusMessage'] + const sealSession: typeof import('../../../../../../node_modules/h3')['sealSession'] + const send: typeof import('../../../../../../node_modules/h3')['send'] + const sendError: typeof import('../../../../../../node_modules/h3')['sendError'] + const sendNoContent: typeof import('../../../../../../node_modules/h3')['sendNoContent'] + const sendProxy: typeof import('../../../../../../node_modules/h3')['sendProxy'] + const sendRedirect: typeof import('../../../../../../node_modules/h3')['sendRedirect'] + const sendStream: typeof import('../../../../../../node_modules/h3')['sendStream'] + const sendWebResponse: typeof import('../../../../../../node_modules/h3')['sendWebResponse'] + const serveStatic: typeof import('../../../../../../node_modules/h3')['serveStatic'] + const setCookie: typeof import('../../../../../../node_modules/h3')['setCookie'] + const setHeader: typeof import('../../../../../../node_modules/h3')['setHeader'] + const setHeaders: typeof import('../../../../../../node_modules/h3')['setHeaders'] + const setResponseHeader: typeof import('../../../../../../node_modules/h3')['setResponseHeader'] + const setResponseHeaders: typeof import('../../../../../../node_modules/h3')['setResponseHeaders'] + const setResponseStatus: typeof import('../../../../../../node_modules/h3')['setResponseStatus'] + const splitCookiesString: typeof import('../../../../../../node_modules/h3')['splitCookiesString'] + const toEventHandler: typeof import('../../../../../../node_modules/h3')['toEventHandler'] + const toNodeListener: typeof import('../../../../../../node_modules/h3')['toNodeListener'] + const toPlainHandler: typeof import('../../../../../../node_modules/h3')['toPlainHandler'] + const toWebHandler: typeof import('../../../../../../node_modules/h3')['toWebHandler'] + const toWebRequest: typeof import('../../../../../../node_modules/h3')['toWebRequest'] + const unsealSession: typeof import('../../../../../../node_modules/h3')['unsealSession'] + const updateSession: typeof import('../../../../../../node_modules/h3')['updateSession'] + const useAppConfig: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['useAppConfig'] + const useBase: typeof import('../../../../../../node_modules/h3')['useBase'] + const useEvent: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['useEvent'] + const useNitroApp: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['useNitroApp'] + const useRuntimeConfig: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['useRuntimeConfig'] + const useSession: typeof import('../../../../../../node_modules/h3')['useSession'] + const useStorage: typeof import('../../../../../../node_modules/nitropack/dist/runtime')['useStorage'] + const writeEarlyHints: typeof import('../../../../../../node_modules/h3')['writeEarlyHints'] +} +export { defineCachedFunction, defineCachedEventHandler, cachedFunction, cachedEventHandler, useRuntimeConfig, useStorage, useNitroApp, defineNitroPlugin, nitroPlugin, defineRenderHandler, getRouteRules, useAppConfig, useEvent } from '../../../../../../node_modules/nitropack/dist/runtime'; +export { appendCorsHeaders, appendCorsPreflightHeaders, appendHeader, appendHeaders, appendResponseHeader, appendResponseHeaders, assertMethod, callNodeListener, clearResponseHeaders, clearSession, createApp, createAppEventHandler, createError, createEvent, createRouter, defaultContentType, defineEventHandler, defineLazyEventHandler, defineNodeListener, defineNodeMiddleware, defineRequestMiddleware, defineResponseMiddleware, deleteCookie, dynamicEventHandler, eventHandler, fetchWithEvent, fromNodeMiddleware, fromPlainHandler, fromWebHandler, getCookie, getHeader, getHeaders, getMethod, getProxyRequestHeaders, getQuery, getRequestHeader, getRequestHeaders, getRequestHost, getRequestIP, getRequestPath, getRequestProtocol, getRequestURL, getRequestWebStream, getResponseHeader, getResponseHeaders, getResponseStatus, getResponseStatusText, getRouterParam, getRouterParams, getSession, getValidatedQuery, handleCacheHeaders, handleCors, isCorsOriginAllowed, isError, isEvent, isEventHandler, isMethod, isPreflightRequest, isStream, isWebResponse, lazyEventHandler, parseCookies, promisifyNodeListener, proxyRequest, readBody, readFormData, readMultipartFormData, readRawBody, readValidatedBody, removeResponseHeader, sanitizeStatusCode, sanitizeStatusMessage, sealSession, send, sendError, sendNoContent, sendProxy, sendRedirect, sendStream, sendWebResponse, serveStatic, setCookie, setHeader, setHeaders, setResponseHeader, setResponseHeaders, setResponseStatus, splitCookiesString, toEventHandler, toNodeListener, toPlainHandler, toWebHandler, toWebRequest, unsealSession, updateSession, useBase, useSession, writeEarlyHints } from 'h3'; +export { buildAssetsURL as __buildAssetsURL, publicAssetsURL as __publicAssetsURL } from '../../../../../../node_modules/nuxt/dist/core/runtime/nitro/paths'; +export { defineAppConfig } from '../../../../../../node_modules/nuxt/dist/core/runtime/nitro/config'; \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-nuxt.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-nuxt.d.ts new file mode 100644 index 000000000..ff88b2b58 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-nuxt.d.ts @@ -0,0 +1,26 @@ + +/// + +import type { RuntimeConfig } from 'nuxt/schema' +import type { H3Event } from 'h3' +import type { NuxtIslandContext, NuxtIslandResponse, NuxtRenderHTMLContext } from 'nuxt/dist/core/runtime/nitro/renderer' + +declare module 'nitropack' { + interface NitroRuntimeConfigApp { + buildAssetsDir: string + cdnURL: string + } + interface NitroRuntimeConfig extends RuntimeConfig {} + interface NitroRouteConfig { + ssr?: boolean + experimentalNoScripts?: boolean + } + interface NitroRouteRules { + ssr?: boolean + experimentalNoScripts?: boolean + } + interface NitroRuntimeHooks { + 'render:html': (htmlContext: NuxtRenderHTMLContext, context: { event: H3Event }) => void | Promise + 'render:island': (islandResponse: NuxtIslandResponse, context: { event: H3Event, islandContext: NuxtIslandContext }) => void | Promise + } +} diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-routes.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-routes.d.ts new file mode 100644 index 000000000..01c2df151 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro-routes.d.ts @@ -0,0 +1,11 @@ +// Generated by nitro +import type { Serialize, Simplify } from 'nitropack' +declare module 'nitropack' { + type Awaited = T extends PromiseLike ? Awaited : T + interface InternalApi { + '/__nuxt_error': { + 'default': Simplify>>> + } + } +} +export {} \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro.d.ts new file mode 100644 index 000000000..bf09bd4d3 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/nitro.d.ts @@ -0,0 +1,3 @@ +/// +/// +/// \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/plugins.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/plugins.d.ts new file mode 100644 index 000000000..83c9e5f0d --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/plugins.d.ts @@ -0,0 +1,27 @@ +// Generated by Nuxt' +import type { Plugin } from '#app' + +type Decorate> = { [K in keyof T as K extends string ? `$${K}` : never]: T[K] } + +type InjectionType = A extends Plugin ? Decorate : unknown + +type NuxtAppInjections = + InjectionType & + InjectionType & + InjectionType & + InjectionType & + InjectionType & + InjectionType & + InjectionType & + InjectionType & + InjectionType + +declare module '#app' { + interface NuxtApp extends NuxtAppInjections { } +} + +declare module 'vue' { + interface ComponentCustomProperties extends NuxtAppInjections { } +} + +export { } diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/schema.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/schema.d.ts new file mode 100644 index 000000000..1978b2942 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/schema.d.ts @@ -0,0 +1,25 @@ +import { NuxtModule, RuntimeConfig } from 'nuxt/schema' +declare module 'nuxt/schema' { + interface NuxtConfig { + ["emotion"]?: typeof import("@nuxtjs/emotion").default extends NuxtModule ? Partial : Record + ["devtools"]?: typeof import("@nuxt/devtools").default extends NuxtModule ? Partial : Record + modules?: (undefined | null | false | NuxtModule | string | [NuxtModule | string, Record] | ["@nuxtjs/emotion", Exclude] | ["@nuxt/devtools", Exclude])[], + } + interface RuntimeConfig { + app: { + baseURL: string, + + buildAssetsDir: string, + + cdnURL: string, + }, + } + interface PublicRuntimeConfig { + + } +} +declare module 'vue' { + interface ComponentCustomProperties { + $config: RuntimeConfig + } + } \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/types/vue-shim.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/vue-shim.d.ts new file mode 100644 index 000000000..3160e5551 --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/types/vue-shim.d.ts @@ -0,0 +1,5 @@ +declare module '*.vue' { + import { DefineComponent } from 'vue' + const component: DefineComponent<{}, {}, any> + export default component +} \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt-typescript/.nuxt/vue-router-stub.d.ts b/packages/vue/examples/with-nuxt-typescript/.nuxt/vue-router-stub.d.ts new file mode 100644 index 000000000..e1866f9ec --- /dev/null +++ b/packages/vue/examples/with-nuxt-typescript/.nuxt/vue-router-stub.d.ts @@ -0,0 +1 @@ +export * from 'vue-router' \ No newline at end of file diff --git a/packages/vue/examples/with-nuxt/package.json b/packages/vue/examples/with-nuxt/package.json index 7376333ac..133255ed9 100644 --- a/packages/vue/examples/with-nuxt/package.json +++ b/packages/vue/examples/with-nuxt/package.json @@ -11,7 +11,7 @@ "generate": "nuxt generate" }, "dependencies": { - "@appbaseio/reactivesearch-vue": "1.35.2", + "@appbaseio/reactivesearch-vue": "1.35.3", "cross-env": "^5.2.0", "nuxt": "^2.0.0" }, diff --git a/packages/vue/examples/with-ssr/package.json b/packages/vue/examples/with-ssr/package.json index 3ee89c894..2e6674cc0 100644 --- a/packages/vue/examples/with-ssr/package.json +++ b/packages/vue/examples/with-ssr/package.json @@ -9,7 +9,7 @@ "generate": "nuxt generate" }, "dependencies": { - "@appbaseio/reactivesearch-vue": "1.35.2", + "@appbaseio/reactivesearch-vue": "1.35.3", "core-js": "^3.15.1", "nuxt": "^2.15.7" }, diff --git a/packages/vue/examples/with-tailwind-css/package.json b/packages/vue/examples/with-tailwind-css/package.json index 84fe26148..6b8d9130c 100644 --- a/packages/vue/examples/with-tailwind-css/package.json +++ b/packages/vue/examples/with-tailwind-css/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "vue": "^2.6.11", - "@appbaseio/reactivesearch-vue": "1.35.2" + "@appbaseio/reactivesearch-vue": "1.35.3" }, "devDependencies": { "@vue/cli-plugin-babel": "~4.3.0",