@nuxt/bridge-edge 3.0.0-28051136.c90f6a2 → 3.0.0-28054996.ab449e5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/chunks/vite.mjs
CHANGED
|
@@ -2,7 +2,7 @@ import { resolve, join, isAbsolute } from 'pathe';
|
|
|
2
2
|
import { logger, isIgnored } from '@nuxt/kit';
|
|
3
3
|
import { findExports, sanitizeFilePath } from 'mlly';
|
|
4
4
|
import { joinURL, withoutLeadingSlash, withTrailingSlash } from 'ufo';
|
|
5
|
-
import { i as isCSS, p as prepareManifests, h as hashId, u as uniq, g as generateDevSSRManifest, d as distDir, a as pkgDir } from '../shared/bridge-edge.
|
|
5
|
+
import { i as isCSS, p as prepareManifests, h as hashId, u as uniq, g as generateDevSSRManifest, d as distDir, a as pkgDir } from '../shared/bridge-edge.be97891c.mjs';
|
|
6
6
|
import createVuePlugin from '@vitejs/plugin-vue2';
|
|
7
7
|
import { getPort } from 'get-port-please';
|
|
8
8
|
import { defineEventHandler } from 'h3';
|
package/dist/module.mjs
CHANGED
|
@@ -2,6 +2,7 @@ import { defu } from "defu";
|
|
|
2
2
|
import { computed, getCurrentInstance as getVM, isReactive, isRef, onBeforeMount, onServerPrefetch, reactive, ref, set, shallowRef, toRaw, toRefs, watch } from "vue";
|
|
3
3
|
import { useNuxtApp } from "./app.mjs";
|
|
4
4
|
import { useRouter as _useRouter, useRoute as _useRoute, useState } from "./composables.mjs";
|
|
5
|
+
import { isFullStatic } from "#build/composition-globals.mjs";
|
|
5
6
|
export {
|
|
6
7
|
computed,
|
|
7
8
|
customRef,
|
|
@@ -415,7 +416,7 @@ export const useFetch = (callback) => {
|
|
|
415
416
|
vm.$fetch = callFetches.bind(vm);
|
|
416
417
|
onBeforeMount(() => !vm._hydrated && callFetches.call(vm));
|
|
417
418
|
if (process.server || !isSsrHydration(vm)) {
|
|
418
|
-
if (process.client &&
|
|
419
|
+
if (process.client && isFullStatic) {
|
|
419
420
|
loadFullStatic(vm);
|
|
420
421
|
}
|
|
421
422
|
return result();
|
|
@@ -568,7 +568,7 @@ async function writeDocumentTemplate(nuxt) {
|
|
|
568
568
|
}
|
|
569
569
|
|
|
570
570
|
const componentsTypeTemplate = {
|
|
571
|
-
filename: "components.d.ts",
|
|
571
|
+
filename: "types/components.d.ts",
|
|
572
572
|
getContents: ({ options }) => `// Generated by components discovery
|
|
573
573
|
declare module 'vue' {
|
|
574
574
|
export interface GlobalComponents {
|
|
@@ -701,6 +701,17 @@ async function setupAppBridge(_options) {
|
|
|
701
701
|
nuxt.hook("prepare:types", ({ references }) => {
|
|
702
702
|
references.push({ path: resolve(nuxt.options.buildDir, "types/schema.d.ts") });
|
|
703
703
|
});
|
|
704
|
+
addTemplate({
|
|
705
|
+
filename: "composition-globals.mjs",
|
|
706
|
+
getContents: () => {
|
|
707
|
+
const globals = {
|
|
708
|
+
// useFetch
|
|
709
|
+
isFullStatic: !nuxt.options.dev && !nuxt.options._legacyGenerate && nuxt.options.target === "static" && nuxt.options.render?.ssr
|
|
710
|
+
};
|
|
711
|
+
const contents = Object.entries(globals).map(([key, value]) => `export const ${key} = ${JSON.stringify(value)}`).join("\n");
|
|
712
|
+
return contents;
|
|
713
|
+
}
|
|
714
|
+
});
|
|
704
715
|
const { dst: vueCompat } = addTemplate({ src: resolve(distDir, "runtime/vue2-bridge.mjs") });
|
|
705
716
|
addWebpackPlugin(VueCompat.webpack({ src: vueCompat }));
|
|
706
717
|
addVitePlugin(VueCompat.vite({ src: vueCompat }));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nuxt/bridge-edge",
|
|
3
|
-
"version": "3.0.0-
|
|
3
|
+
"version": "3.0.0-28054996.ab449e5",
|
|
4
4
|
"repository": "nuxt/bridge",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.18.6",
|
|
20
20
|
"@babel/plugin-proposal-optional-chaining": "^7.21.0",
|
|
21
21
|
"@babel/plugin-transform-typescript": "^7.21.3",
|
|
22
|
-
"@nuxt/bridge-schema": "npm:@nuxt/bridge-schema-edge@3.0.0-
|
|
22
|
+
"@nuxt/bridge-schema": "npm:@nuxt/bridge-schema-edge@3.0.0-28054996.ab449e5",
|
|
23
23
|
"@nuxt/devalue": "^2.0.2",
|
|
24
24
|
"@nuxt/kit": "3.4.3",
|
|
25
25
|
"@nuxt/postcss8": "^1.1.3",
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
"ofetch": "^1.0.1",
|
|
50
50
|
"ohash": "^1.1.2",
|
|
51
51
|
"pathe": "^1.1.0",
|
|
52
|
-
"perfect-debounce": "^0.
|
|
52
|
+
"perfect-debounce": "^1.0.0",
|
|
53
53
|
"postcss": "^8.4.23",
|
|
54
54
|
"postcss-import": "^15.1.0",
|
|
55
55
|
"postcss-import-resolver": "^2.0.0",
|