nuxt-schema-org 1.0.0-beta.4 → 1.0.0-beta.7

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/module.json CHANGED
@@ -4,5 +4,5 @@
4
4
  "bridge": false
5
5
  },
6
6
  "name": "nuxt-schema-org",
7
- "version": "1.0.0-beta.4"
7
+ "version": "1.0.0-beta.7"
8
8
  }
package/dist/module.mjs CHANGED
@@ -19,18 +19,22 @@ const module = defineNuxtModule({
19
19
  nuxt.options.build.transpile.push(...[moduleRuntimeDir, RuntimeDir]);
20
20
  if (typeof moduleOptions.client === "undefined")
21
21
  moduleOptions.client = !!nuxt.options.dev;
22
+ const nuxtSchemaComposablesRuntime = `${moduleRuntimeDir}/composables`;
23
+ const providerPath = await resolvePath(`${schemaOrgPath}/providers/${moduleOptions.full ? "full" : "simple"}`);
24
+ nuxt.options.alias[Pkg] = schemaOrgPath;
25
+ nuxt.options.alias["#vueuse/schema-org/provider"] = providerPath;
26
+ nuxt.options.alias["#vueuse/schema-org/runtime"] = nuxtSchemaComposablesRuntime;
22
27
  if (!moduleOptions.client)
23
28
  addPlugin(resolve(moduleRuntimeDir, "plugin-fallback.client"));
24
29
  addPlugin({
25
30
  src: resolve(moduleRuntimeDir, "plugin"),
26
31
  mode: moduleOptions.client ? "all" : "server"
27
32
  });
28
- const nuxtSchemaComposablesRuntime = `${moduleRuntimeDir}/composables`;
29
33
  addTemplate({
30
34
  filename: "nuxt-schema-org-config.mjs",
31
35
  getContents: () => `export default ${JSON.stringify(moduleOptions)}`
32
36
  });
33
- const componentPath = await resolvePath("@vueuse/schema-org/components");
37
+ const componentPath = await resolvePath(`${schemaOrgPath}/runtime/components`);
34
38
  for (const component of schemaOrgComponents) {
35
39
  await addComponent({
36
40
  name: component,
@@ -62,7 +66,11 @@ const module = defineNuxtModule({
62
66
  config.plugins.push(SchemaOrg({
63
67
  mock: !moduleOptions.client && isClient,
64
68
  full: moduleOptions.full,
65
- runtimePath: nuxtSchemaComposablesRuntime
69
+ aliasPaths: {
70
+ provider: providerPath,
71
+ pkgDir: schemaOrgPath,
72
+ runtime: nuxtSchemaComposablesRuntime
73
+ }
66
74
  }));
67
75
  });
68
76
  }
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "nuxt-schema-org",
3
- "version": "1.0.0-beta.4",
3
+ "type": "module",
4
+ "version": "1.0.0-beta.7",
4
5
  "description": "Nuxt module for @vueuse/schema-org",
5
6
  "author": "Harlan Wilton <harlan@harlanzw.com>",
6
7
  "license": "MIT",
@@ -21,10 +22,8 @@
21
22
  "nuxt-module",
22
23
  "nuxt3"
23
24
  ],
24
- "sideEffects": false,
25
25
  "exports": {
26
26
  ".": {
27
- "types": "./dist/types.d.ts",
28
27
  "require": "./dist/module.cjs",
29
28
  "import": "./dist/module.mjs"
30
29
  }
@@ -36,8 +35,8 @@
36
35
  ],
37
36
  "dependencies": {
38
37
  "@nuxt/kit": "3.0.0-rc.8",
39
- "@vueuse/schema-org": "1.0.0-beta.4",
40
- "@vueuse/schema-org-vite": "1.0.0-beta.4",
38
+ "@vueuse/schema-org": "1.0.0-beta.7",
39
+ "@vueuse/schema-org-vite": "1.0.0-beta.7",
41
40
  "pathe": "^0.3.4",
42
41
  "schema-org-graph-js": "0.3.3"
43
42
  },