@web-widget/vue 1.51.1 → 1.52.0

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.
Files changed (2) hide show
  1. package/dist/vite.js +4 -7
  2. package/package.json +6 -6
package/dist/vite.js CHANGED
@@ -1,6 +1,5 @@
1
1
  // src/vite.ts
2
2
  import { webWidgetPlugin } from "@web-widget/vite-plugin";
3
- var VUE_INTERNAL_REQUEST = /\.vue\?(?:direct&)?vue\b.*$/;
4
3
  var VUE_INTERNAL_SCRIPT_REQUEST = /\.vue\?vue&type=script\b.*$/;
5
4
  function vueWebWidgetPlugin(options) {
6
5
  const {
@@ -9,14 +8,13 @@ function vueWebWidgetPlugin(options) {
9
8
  export: exportWidget = {},
10
9
  import: importWidget = {}
11
10
  } = options != null ? options : {};
12
- const route = /(?:\.|@)route\.vue(?:\?.*)?$/;
13
- const widget = /(?:\.|@)widget\.vue(?:\?.*)?$/;
11
+ const route = /(?:\.|@)route\.vue(?:\?as=.+)?$/;
12
+ const widget = /(?:\.|@)widget\.vue(?:\?as=.+)?$/;
14
13
  return webWidgetPlugin({
15
14
  manifest,
16
15
  provide,
17
16
  export: {
18
17
  include: [route, widget],
19
- exclude: VUE_INTERNAL_REQUEST,
20
18
  extractFromExportDefault: [
21
19
  {
22
20
  name: "handler",
@@ -32,11 +30,10 @@ function vueWebWidgetPlugin(options) {
32
30
  ...exportWidget
33
31
  },
34
32
  import: {
35
- include: /(?:\.|@)widget\..*$/,
36
- exclude: VUE_INTERNAL_REQUEST,
33
+ include: /(?:\.|@)widget\.[^?]*(?:\?as=.+)?$/,
37
34
  includeImporter: [
38
35
  // vite: dev mode
39
- /\.vue$/,
36
+ /\.vue(?:\?as=.+)?$/,
40
37
  // vite: build mode
41
38
  VUE_INTERNAL_SCRIPT_REQUEST
42
39
  ],
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@web-widget/vue",
3
3
  "description": "Vue adapter",
4
- "version": "1.51.1",
4
+ "version": "1.52.0",
5
5
  "homepage": "https://github.com/web-widget/web-widget#readme",
6
6
  "repository": {
7
7
  "type": "git",
@@ -13,11 +13,11 @@
13
13
  },
14
14
  "license": "MIT",
15
15
  "dependencies": {
16
- "@web-widget/helpers": "1.51.1",
17
- "@web-widget/vite-plugin": "1.51.1",
18
- "@web-widget/web-widget": "1.51.1",
19
- "@web-widget/schema": "1.51.1",
20
- "@web-widget/react": "1.51.1"
16
+ "@web-widget/helpers": "1.52.0",
17
+ "@web-widget/vite-plugin": "1.52.0",
18
+ "@web-widget/web-widget": "1.52.0",
19
+ "@web-widget/schema": "1.52.0",
20
+ "@web-widget/react": "1.52.0"
21
21
  },
22
22
  "devDependencies": {
23
23
  "tsup": "^8.3.4",