vue-jsx-vapor 2.2.0 → 2.3.1

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 (87) hide show
  1. package/dist/api.cjs +2 -5
  2. package/dist/api.d.cts +6 -7
  3. package/dist/api.d.ts +6 -7
  4. package/dist/api.js +3 -6
  5. package/dist/astro.cjs +14 -18
  6. package/dist/astro.d.cts +4 -5
  7. package/dist/astro.d.ts +4 -5
  8. package/dist/astro.js +13 -17
  9. package/dist/chunk-BCwAaXi7.cjs +31 -0
  10. package/dist/core-B29W1zp3.cjs +32 -0
  11. package/dist/core-BDE4GLH8.js +25 -0
  12. package/dist/esbuild.cjs +12 -14
  13. package/dist/esbuild.d.cts +6 -7
  14. package/dist/esbuild.d.ts +6 -7
  15. package/dist/esbuild.js +8 -10
  16. package/dist/index.cjs +66 -78
  17. package/dist/index.d.cts +4 -3
  18. package/dist/index.d.ts +4 -3
  19. package/dist/index.js +59 -80
  20. package/dist/jsx-runtime.cjs +14 -13
  21. package/dist/jsx-runtime.d.cts +24 -23
  22. package/dist/jsx-runtime.d.ts +24 -23
  23. package/dist/jsx-runtime.js +9 -13
  24. package/dist/nuxt.cjs +23 -26
  25. package/dist/nuxt.d.cts +6 -7
  26. package/dist/nuxt.d.ts +6 -7
  27. package/dist/nuxt.js +19 -23
  28. package/dist/options-HYvLzmlg.js +0 -0
  29. package/dist/options.cjs +1 -1
  30. package/dist/options.d-BAyccQwr.d.ts +20 -0
  31. package/dist/options.d-CA70vgwp.d.cts +20 -0
  32. package/dist/options.d.cts +2 -17
  33. package/dist/options.d.ts +2 -17
  34. package/dist/options.js +1 -1
  35. package/dist/raw-C8eD8f6a.js +214 -0
  36. package/dist/raw-Dr3UcxgN.cjs +221 -0
  37. package/dist/raw.cjs +4 -8
  38. package/dist/raw.d.cts +5 -6
  39. package/dist/raw.d.ts +5 -6
  40. package/dist/raw.js +4 -7
  41. package/dist/rolldown.cjs +14 -15
  42. package/dist/rolldown.d.cts +6 -7
  43. package/dist/rolldown.d.ts +6 -7
  44. package/dist/rolldown.js +9 -11
  45. package/dist/rollup.cjs +12 -14
  46. package/dist/rollup.d.cts +6 -7
  47. package/dist/rollup.d.ts +6 -7
  48. package/dist/rollup.js +8 -10
  49. package/dist/rspack.cjs +12 -14
  50. package/dist/rspack.d.cts +4 -5
  51. package/dist/rspack.d.ts +4 -5
  52. package/dist/rspack.js +8 -10
  53. package/dist/unplugin-BMMTjSOs.js +32 -0
  54. package/dist/unplugin-ChZxAtQ0.cjs +51 -0
  55. package/dist/unplugin.cjs +9 -13
  56. package/dist/unplugin.d.cts +6 -8
  57. package/dist/unplugin.d.ts +6 -8
  58. package/dist/unplugin.js +6 -13
  59. package/dist/vite-BSUI3W42.js +7 -0
  60. package/dist/vite-D_zoULH4.cjs +13 -0
  61. package/dist/vite.cjs +8 -12
  62. package/dist/vite.d.cts +6 -7
  63. package/dist/vite.d.ts +6 -7
  64. package/dist/vite.js +7 -10
  65. package/dist/volar.cjs +18 -18
  66. package/dist/volar.d.cts +5 -6
  67. package/dist/volar.d.ts +5 -6
  68. package/dist/volar.js +12 -13
  69. package/dist/webpack-BXmoWpIv.cjs +13 -0
  70. package/dist/webpack-CeYJ9dJv.js +7 -0
  71. package/dist/webpack.cjs +8 -12
  72. package/dist/webpack.d.cts +6 -7
  73. package/dist/webpack.d.ts +6 -7
  74. package/dist/webpack.js +7 -10
  75. package/package.json +6 -6
  76. package/dist/chunk-4HP6QVER.js +0 -10
  77. package/dist/chunk-F7CI4ATH.cjs +0 -43
  78. package/dist/chunk-G2KD2VHX.js +0 -43
  79. package/dist/chunk-GODVM7NB.cjs +0 -1
  80. package/dist/chunk-GY6DSRCV.cjs +0 -22
  81. package/dist/chunk-HNBQ42EP.js +0 -10
  82. package/dist/chunk-M4VKLZSB.cjs +0 -10
  83. package/dist/chunk-QBIU4H54.cjs +0 -10
  84. package/dist/chunk-SAJ6WS2A.js +0 -22
  85. package/dist/chunk-T3F6TYMY.js +0 -265
  86. package/dist/chunk-VSS2IZIS.cjs +0 -265
  87. /package/dist/{chunk-JNAGPWSX.js → options-CulFO0WS.cjs} +0 -0
package/dist/api.cjs CHANGED
@@ -1,6 +1,3 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
1
+ const require_core = require('./core-B29W1zp3.cjs');
2
2
 
3
- var _chunkGY6DSRCVcjs = require('./chunk-GY6DSRCV.cjs');
4
-
5
-
6
- exports.transformVueJsxVapor = _chunkGY6DSRCVcjs.transformVueJsxVapor;
3
+ exports.transformVueJsxVapor = require_core.transformVueJsxVapor
package/dist/api.d.cts CHANGED
@@ -1,9 +1,8 @@
1
- import * as _babel_core from '@babel/core';
2
- import { Options } from './options.cjs';
3
- import '@vue-jsx-vapor/compiler';
4
- import '@vue-jsx-vapor/macros';
5
- import 'unplugin-utils';
1
+ import { Options } from "./options.d-CA70vgwp.cjs";
2
+ import { BabelFileResult } from "@babel/core";
6
3
 
7
- declare function transformVueJsxVapor(code: string, id: string, options?: Options, needSourceMap?: boolean): _babel_core.BabelFileResult | null;
4
+ //#region src/core/index.d.ts
5
+ declare function transformVueJsxVapor(code: string, id: string, options?: Options, needSourceMap?: boolean): BabelFileResult | null;
8
6
 
9
- export { Options, transformVueJsxVapor };
7
+ //#endregion
8
+ export { Options, transformVueJsxVapor };
package/dist/api.d.ts CHANGED
@@ -1,9 +1,8 @@
1
- import * as _babel_core from '@babel/core';
2
- import { Options } from './options.js';
3
- import '@vue-jsx-vapor/compiler';
4
- import '@vue-jsx-vapor/macros';
5
- import 'unplugin-utils';
1
+ import { Options } from "./options.d-BAyccQwr.js";
2
+ import { BabelFileResult } from "@babel/core";
6
3
 
7
- declare function transformVueJsxVapor(code: string, id: string, options?: Options, needSourceMap?: boolean): _babel_core.BabelFileResult | null;
4
+ //#region src/core/index.d.ts
5
+ declare function transformVueJsxVapor(code: string, id: string, options?: Options, needSourceMap?: boolean): BabelFileResult | null;
8
6
 
9
- export { Options, transformVueJsxVapor };
7
+ //#endregion
8
+ export { Options, transformVueJsxVapor };
package/dist/api.js CHANGED
@@ -1,6 +1,3 @@
1
- import {
2
- transformVueJsxVapor
3
- } from "./chunk-SAJ6WS2A.js";
4
- export {
5
- transformVueJsxVapor
6
- };
1
+ import { transformVueJsxVapor } from "./core-BDE4GLH8.js";
2
+
3
+ export { transformVueJsxVapor };
package/dist/astro.cjs CHANGED
@@ -1,22 +1,18 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
1
+ "use strict";
2
+ Object.defineProperty(exports, '__esModule', { value: true });
3
+ require('./core-B29W1zp3.cjs');
4
+ require('./raw-Dr3UcxgN.cjs');
5
+ require('./options-CulFO0WS.cjs');
6
+ const require_unplugin = require('./unplugin-ChZxAtQ0.cjs');
2
7
 
3
- var _chunkF7CI4ATHcjs = require('./chunk-F7CI4ATH.cjs');
4
- require('./chunk-GODVM7NB.cjs');
5
- require('./chunk-VSS2IZIS.cjs');
6
- require('./chunk-GY6DSRCV.cjs');
7
-
8
- // src/astro.ts
8
+ //#region src/astro.ts
9
9
  var astro_default = (options) => ({
10
- name: "vue-jsx-vapor",
11
- hooks: {
12
- "astro:config:setup": (astro) => {
13
- astro.config.vite.plugins ||= [];
14
- astro.config.vite.plugins.push(_chunkF7CI4ATHcjs.unplugin_default.vite(options));
15
- }
16
- }
10
+ name: "vue-jsx-vapor",
11
+ hooks: { "astro:config:setup": (astro) => {
12
+ astro.config.vite.plugins ||= [];
13
+ astro.config.vite.plugins.push(require_unplugin.unplugin_default.vite(options));
14
+ } }
17
15
  });
18
16
 
19
-
20
- exports.default = astro_default;
21
-
22
- module.exports = exports.default;
17
+ //#endregion
18
+ exports.default = astro_default
package/dist/astro.d.cts CHANGED
@@ -1,8 +1,6 @@
1
- import { Options } from './options.cjs';
2
- import '@vue-jsx-vapor/compiler';
3
- import '@vue-jsx-vapor/macros';
4
- import 'unplugin-utils';
1
+ import { Options } from "./options.d-CA70vgwp.cjs";
5
2
 
3
+ //#region src/astro.d.ts
6
4
  declare const _default: (options: Options) => {
7
5
  name: string;
8
6
  hooks: {
@@ -10,4 +8,5 @@ declare const _default: (options: Options) => {
10
8
  };
11
9
  };
12
10
 
13
- export = _default;
11
+ //#endregion
12
+ export { _default as default };
package/dist/astro.d.ts CHANGED
@@ -1,8 +1,6 @@
1
- import { Options } from './options.js';
2
- import '@vue-jsx-vapor/compiler';
3
- import '@vue-jsx-vapor/macros';
4
- import 'unplugin-utils';
1
+ import { Options } from "./options.d-BAyccQwr.js";
5
2
 
3
+ //#region src/astro.d.ts
6
4
  declare const _default: (options: Options) => {
7
5
  name: string;
8
6
  hooks: {
@@ -10,4 +8,5 @@ declare const _default: (options: Options) => {
10
8
  };
11
9
  };
12
10
 
13
- export { _default as default };
11
+ //#endregion
12
+ export { _default as default };
package/dist/astro.js CHANGED
@@ -1,20 +1,16 @@
1
- import {
2
- unplugin_default
3
- } from "./chunk-G2KD2VHX.js";
4
- import "./chunk-JNAGPWSX.js";
5
- import "./chunk-T3F6TYMY.js";
6
- import "./chunk-SAJ6WS2A.js";
1
+ import "./core-BDE4GLH8.js";
2
+ import "./raw-C8eD8f6a.js";
3
+ import "./options-HYvLzmlg.js";
4
+ import { unplugin_default } from "./unplugin-BMMTjSOs.js";
7
5
 
8
- // src/astro.ts
6
+ //#region src/astro.ts
9
7
  var astro_default = (options) => ({
10
- name: "vue-jsx-vapor",
11
- hooks: {
12
- "astro:config:setup": (astro) => {
13
- astro.config.vite.plugins ||= [];
14
- astro.config.vite.plugins.push(unplugin_default.vite(options));
15
- }
16
- }
8
+ name: "vue-jsx-vapor",
9
+ hooks: { "astro:config:setup": (astro) => {
10
+ astro.config.vite.plugins ||= [];
11
+ astro.config.vite.plugins.push(unplugin_default.vite(options));
12
+ } }
17
13
  });
18
- export {
19
- astro_default as default
20
- };
14
+
15
+ //#endregion
16
+ export { astro_default as default };
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ //#region rolldown:runtime
3
+ var __create = Object.create;
4
+ var __defProp = Object.defineProperty;
5
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
+ var __getOwnPropNames = Object.getOwnPropertyNames;
7
+ var __getProtoOf = Object.getPrototypeOf;
8
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
9
+ var __copyProps = (to, from, except, desc) => {
10
+ if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
11
+ key = keys[i];
12
+ if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
13
+ get: ((k) => from[k]).bind(null, key),
14
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
15
+ });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
20
+ value: mod,
21
+ enumerable: true
22
+ }) : target, mod));
23
+
24
+ //#endregion
25
+
26
+ Object.defineProperty(exports, '__toESM', {
27
+ enumerable: true,
28
+ get: function () {
29
+ return __toESM;
30
+ }
31
+ });
@@ -0,0 +1,32 @@
1
+ "use strict";
2
+ const require_chunk = require('./chunk-BCwAaXi7.cjs');
3
+ const __babel_core = require_chunk.__toESM(require("@babel/core"));
4
+ const __babel_plugin_transform_typescript = require_chunk.__toESM(require("@babel/plugin-transform-typescript"));
5
+ const __vue_jsx_vapor_babel = require_chunk.__toESM(require("@vue-jsx-vapor/babel"));
6
+
7
+ //#region src/core/index.ts
8
+ function transformVueJsxVapor(code, id, options, needSourceMap = false) {
9
+ return (0, __babel_core.transformSync)(code, {
10
+ plugins: [[__vue_jsx_vapor_babel.default, {
11
+ compile: options?.compile,
12
+ interop: options?.interop
13
+ }], ...id.endsWith(".tsx") ? [[__babel_plugin_transform_typescript.default, {
14
+ isTSX: true,
15
+ allowExtensions: true
16
+ }]] : []],
17
+ filename: id,
18
+ sourceMaps: needSourceMap,
19
+ sourceFileName: id,
20
+ babelrc: false,
21
+ configFile: false,
22
+ ast: true
23
+ });
24
+ }
25
+
26
+ //#endregion
27
+ Object.defineProperty(exports, 'transformVueJsxVapor', {
28
+ enumerable: true,
29
+ get: function () {
30
+ return transformVueJsxVapor;
31
+ }
32
+ });
@@ -0,0 +1,25 @@
1
+ import { transformSync } from "@babel/core";
2
+ import babelTypescript from "@babel/plugin-transform-typescript";
3
+ import jsx from "@vue-jsx-vapor/babel";
4
+
5
+ //#region src/core/index.ts
6
+ function transformVueJsxVapor(code, id, options, needSourceMap = false) {
7
+ return transformSync(code, {
8
+ plugins: [[jsx, {
9
+ compile: options?.compile,
10
+ interop: options?.interop
11
+ }], ...id.endsWith(".tsx") ? [[babelTypescript, {
12
+ isTSX: true,
13
+ allowExtensions: true
14
+ }]] : []],
15
+ filename: id,
16
+ sourceMaps: needSourceMap,
17
+ sourceFileName: id,
18
+ babelrc: false,
19
+ configFile: false,
20
+ ast: true
21
+ });
22
+ }
23
+
24
+ //#endregion
25
+ export { transformVueJsxVapor };
package/dist/esbuild.cjs CHANGED
@@ -1,14 +1,12 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
- var _chunkF7CI4ATHcjs = require('./chunk-F7CI4ATH.cjs');
4
- require('./chunk-GODVM7NB.cjs');
5
- require('./chunk-VSS2IZIS.cjs');
6
- require('./chunk-GY6DSRCV.cjs');
7
-
8
- // src/esbuild.ts
9
- var esbuild_default = _chunkF7CI4ATHcjs.unplugin_default.esbuild;
10
-
11
-
12
- exports.default = esbuild_default;
13
-
14
- module.exports = exports.default;
1
+ "use strict";
2
+ Object.defineProperty(exports, '__esModule', { value: true });
3
+ require('./core-B29W1zp3.cjs');
4
+ require('./raw-Dr3UcxgN.cjs');
5
+ require('./options-CulFO0WS.cjs');
6
+ const require_unplugin = require('./unplugin-ChZxAtQ0.cjs');
7
+
8
+ //#region src/esbuild.ts
9
+ var esbuild_default = require_unplugin.unplugin_default.esbuild;
10
+
11
+ //#endregion
12
+ exports.default = esbuild_default
@@ -1,9 +1,8 @@
1
- import * as esbuild from 'esbuild';
2
- import { Options } from './options.cjs';
3
- import '@vue-jsx-vapor/compiler';
4
- import '@vue-jsx-vapor/macros';
5
- import 'unplugin-utils';
1
+ import { Options } from "./options.d-CA70vgwp.cjs";
2
+ import { Plugin } from "esbuild";
6
3
 
7
- declare const _default: (options?: Options | undefined) => esbuild.Plugin;
4
+ //#region src/esbuild.d.ts
5
+ declare const _default: (options?: Options | undefined) => Plugin;
8
6
 
9
- export = _default;
7
+ //#endregion
8
+ export { _default as default };
package/dist/esbuild.d.ts CHANGED
@@ -1,9 +1,8 @@
1
- import * as esbuild from 'esbuild';
2
- import { Options } from './options.js';
3
- import '@vue-jsx-vapor/compiler';
4
- import '@vue-jsx-vapor/macros';
5
- import 'unplugin-utils';
1
+ import { Options } from "./options.d-BAyccQwr.js";
2
+ import { Plugin } from "esbuild";
6
3
 
7
- declare const _default: (options?: Options | undefined) => esbuild.Plugin;
4
+ //#region src/esbuild.d.ts
5
+ declare const _default: (options?: Options | undefined) => Plugin;
8
6
 
9
- export { _default as default };
7
+ //#endregion
8
+ export { _default as default };
package/dist/esbuild.js CHANGED
@@ -1,12 +1,10 @@
1
- import {
2
- unplugin_default
3
- } from "./chunk-G2KD2VHX.js";
4
- import "./chunk-JNAGPWSX.js";
5
- import "./chunk-T3F6TYMY.js";
6
- import "./chunk-SAJ6WS2A.js";
1
+ import "./core-BDE4GLH8.js";
2
+ import "./raw-C8eD8f6a.js";
3
+ import "./options-HYvLzmlg.js";
4
+ import { unplugin_default } from "./unplugin-BMMTjSOs.js";
7
5
 
8
- // src/esbuild.ts
6
+ //#region src/esbuild.ts
9
7
  var esbuild_default = unplugin_default.esbuild;
10
- export {
11
- esbuild_default as default
12
- };
8
+
9
+ //#endregion
10
+ export { esbuild_default as default };
package/dist/index.cjs CHANGED
@@ -1,92 +1,80 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/core/runtime.ts
2
-
3
-
4
-
5
-
6
-
7
-
8
-
9
- var _vue = require('vue');
1
+ "use strict";
2
+ const require_chunk = require('./chunk-BCwAaXi7.cjs');
3
+ const vue = require_chunk.__toESM(require("vue"));
10
4
 
5
+ //#region src/core/runtime.ts
11
6
  function createFragment(nodes, anchor = document.createTextNode("")) {
12
- const frag = new (0, _vue.VaporFragment)(nodes);
13
- frag.anchor = anchor;
14
- return frag;
7
+ const frag = new vue.VaporFragment(nodes);
8
+ frag.anchor = anchor;
9
+ return frag;
15
10
  }
16
11
  function normalizeValue(value, anchor) {
17
- if (value instanceof Node || _vue.isFragment.call(void 0, value)) {
18
- anchor && (anchor.textContent = "");
19
- return value;
20
- } else if (Array.isArray(value)) {
21
- anchor && (anchor.textContent = "");
22
- return createFragment(
23
- value.map((i) => normalizeValue(i)),
24
- anchor
25
- );
26
- } else {
27
- const result = value == null || typeof value === "boolean" ? "" : String(value);
28
- if (anchor) {
29
- anchor.textContent = result;
30
- return anchor;
31
- } else {
32
- return document.createTextNode(result);
33
- }
34
- }
12
+ if (value instanceof Node || (0, vue.isFragment)(value)) {
13
+ anchor && (anchor.textContent = "");
14
+ return value;
15
+ } else if (Array.isArray(value)) {
16
+ anchor && (anchor.textContent = "");
17
+ return createFragment(value.map((i) => normalizeValue(i)), anchor);
18
+ } else {
19
+ const result = value == null || typeof value === "boolean" ? "" : String(value);
20
+ if (anchor) {
21
+ anchor.textContent = result;
22
+ return anchor;
23
+ } else return document.createTextNode(result);
24
+ }
35
25
  }
36
26
  function resolveValue(current, value, anchor) {
37
- const node = normalizeValue(value, anchor);
38
- if (current) {
39
- if (_vue.isFragment.call(void 0, current)) {
40
- const { anchor: anchor2 } = current;
41
- if (anchor2 && anchor2.parentNode) {
42
- _vue.remove.call(void 0, current.nodes, anchor2.parentNode);
43
- _vue.insert.call(void 0, node, anchor2.parentNode, anchor2);
44
- anchor2.remove();
45
- }
46
- } else if (current instanceof Node) {
47
- if (_vue.isFragment.call(void 0, node) && current.parentNode) {
48
- _vue.insert.call(void 0, node, current.parentNode, current);
49
- current.remove();
50
- } else if (node instanceof Node) {
51
- if (current.nodeType === 3 && node.nodeType === 3) {
52
- current.textContent = node.textContent;
53
- return current;
54
- } else if (current.parentNode) {
55
- current.parentNode.replaceChild(node, current);
56
- }
57
- }
58
- }
59
- }
60
- return node;
27
+ const node = normalizeValue(value, anchor);
28
+ if (current) {
29
+ if ((0, vue.isFragment)(current)) {
30
+ const { anchor: anchor$1 } = current;
31
+ if (anchor$1 && anchor$1.parentNode) {
32
+ (0, vue.remove)(current.nodes, anchor$1.parentNode);
33
+ (0, vue.insert)(node, anchor$1.parentNode, anchor$1);
34
+ anchor$1.remove();
35
+ }
36
+ } else if (current instanceof Node) {
37
+ if ((0, vue.isFragment)(node) && current.parentNode) {
38
+ (0, vue.insert)(node, current.parentNode, current);
39
+ current.remove();
40
+ } else if (node instanceof Node) {
41
+ if (current.nodeType === 3 && node.nodeType === 3) {
42
+ current.textContent = node.textContent;
43
+ return current;
44
+ } else if (current.parentNode) current.parentNode.replaceChild(node, current);
45
+ }
46
+ }
47
+ }
48
+ return node;
61
49
  }
62
50
  function resolveValues(values = [], _anchor) {
63
- const nodes = [];
64
- const scopes = [];
65
- for (const [index, value] of values.entries()) {
66
- const anchor = index === values.length - 1 ? _anchor : void 0;
67
- if (typeof value === "function") {
68
- _vue.renderEffect.call(void 0, () => {
69
- if (scopes[index]) scopes[index].stop();
70
- scopes[index] = _vue.effectScope.call(void 0, );
71
- nodes[index] = scopes[index].run(
72
- () => resolveValue(nodes[index], value(), anchor)
73
- );
74
- });
75
- } else {
76
- nodes[index] = resolveValue(nodes[index], value, anchor);
77
- }
78
- }
79
- return nodes;
51
+ const nodes = [];
52
+ const scopes = [];
53
+ for (const [index, value] of values.entries()) {
54
+ const anchor = index === values.length - 1 ? _anchor : void 0;
55
+ if (typeof value === "function") (0, vue.renderEffect)(() => {
56
+ if (scopes[index]) scopes[index].stop();
57
+ scopes[index] = (0, vue.effectScope)();
58
+ nodes[index] = scopes[index].run(() => resolveValue(nodes[index], value(), anchor));
59
+ });
60
+ else nodes[index] = resolveValue(nodes[index], value, anchor);
61
+ }
62
+ return nodes;
80
63
  }
81
64
  function setNodes(anchor, ...values) {
82
- const resolvedValues = resolveValues(values, anchor);
83
- anchor.parentNode && _vue.insert.call(void 0, resolvedValues, anchor.parentNode, anchor);
65
+ const resolvedValues = resolveValues(values, anchor);
66
+ anchor.parentNode && (0, vue.insert)(resolvedValues, anchor.parentNode, anchor);
84
67
  }
85
68
  function createNodes(...values) {
86
- return resolveValues(values);
69
+ return resolveValues(values);
87
70
  }
88
71
 
89
-
90
-
91
-
92
- exports.createNodes = createNodes; exports.setNodes = setNodes; exports.useRef = _vue.shallowRef;
72
+ //#endregion
73
+ exports.createNodes = createNodes
74
+ exports.setNodes = setNodes
75
+ Object.defineProperty(exports, 'useRef', {
76
+ enumerable: true,
77
+ get: function () {
78
+ return vue.shallowRef;
79
+ }
80
+ });
package/dist/index.d.cts CHANGED
@@ -1,7 +1,8 @@
1
- import { Block } from 'vue';
2
- export { shallowRef as useRef } from 'vue';
1
+ import { shallowRef as useRef } from "vue";
3
2
 
3
+ //#region src/core/runtime.d.ts
4
4
  declare function setNodes(anchor: Element, ...values: any[]): void;
5
5
  declare function createNodes(...values: any[]): Block[];
6
6
 
7
- export { createNodes, setNodes };
7
+ //#endregion
8
+ export { createNodes, setNodes, useRef };
package/dist/index.d.ts CHANGED
@@ -1,7 +1,8 @@
1
- import { Block } from 'vue';
2
- export { shallowRef as useRef } from 'vue';
1
+ import { shallowRef as useRef } from "vue";
3
2
 
3
+ //#region src/core/runtime.d.ts
4
4
  declare function setNodes(anchor: Element, ...values: any[]): void;
5
5
  declare function createNodes(...values: any[]): Block[];
6
6
 
7
- export { createNodes, setNodes };
7
+ //#endregion
8
+ export { createNodes, setNodes, useRef };