@razaman2/reactive-view 0.0.24 → 0.0.26

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/index.d.mts CHANGED
@@ -45,9 +45,7 @@ declare const _default: {
45
45
  ReactiveView: {
46
46
  default: boolean;
47
47
  };
48
- instance: {
49
- default: vue.Ref<any, any>;
50
- };
48
+ instance: {};
51
49
  notifications: ObjectConstructor;
52
50
  subscriptions: ObjectConstructor;
53
51
  beforeSetData: FunctionConstructor;
package/dist/index.d.ts CHANGED
@@ -45,9 +45,7 @@ declare const _default: {
45
45
  ReactiveView: {
46
46
  default: boolean;
47
47
  };
48
- instance: {
49
- default: vue.Ref<any, any>;
50
- };
48
+ instance: {};
51
49
  notifications: ObjectConstructor;
52
50
  subscriptions: ObjectConstructor;
53
51
  beforeSetData: FunctionConstructor;
package/dist/index.js CHANGED
@@ -159,7 +159,7 @@ var import_vue = require("vue");
159
159
 
160
160
  // package.json
161
161
  var name = "@razaman2/reactive-view";
162
- var version = "0.0.24";
162
+ var version = "0.0.26";
163
163
 
164
164
  // src/ReactiveView.ts
165
165
  var setup = {
@@ -172,9 +172,7 @@ var ReactiveView_default = {
172
172
  ReactiveView: {
173
173
  default: true
174
174
  },
175
- instance: {
176
- default: (0, import_vue.ref)()
177
- },
175
+ instance: {},
178
176
  notifications: Object,
179
177
  subscriptions: Object,
180
178
  beforeSetData: Function,
@@ -300,11 +298,11 @@ var ReactiveView_default = {
300
298
  const component = (0, import_vue.ref)({ parent: { self: instance.proxy }, self: { template, model, isValid } });
301
299
  if (access(component).ReactiveView) {
302
300
  component.value = [access(component)].reduce((options, parent) => {
303
- var _a2;
301
+ var _a2, _b2;
304
302
  while (parent) {
305
303
  if (typeof parent.setup === "function") {
306
- options = { parent: options, self: (_a2 = parent.setup(component, options)) != null ? _a2 : {} };
307
- console.log("log options:", options);
304
+ const ups = parent.setup(component, options);
305
+ options = { parent: options, self: (_b2 = (_a2 = ups.value) != null ? _a2 : ups) != null ? _b2 : {} };
308
306
  if (access(parent.$parent).ReactiveView) {
309
307
  break;
310
308
  } else {
@@ -317,9 +315,9 @@ var ReactiveView_default = {
317
315
  return options;
318
316
  }, component.value);
319
317
  }
320
- console.log("component before:", component.value);
321
- props.instance.value = component.value;
322
- console.log("component after:", component.value, props.instance.value);
318
+ if (props.instance) {
319
+ props.instance.value = component.value;
320
+ }
323
321
  return (vue) => {
324
322
  if (ready.value) {
325
323
  return access(component).template(component, vue);
package/dist/index.mjs CHANGED
@@ -119,7 +119,7 @@ import { ref, reactive, watch, isRef, isReactive, createVNode, getCurrentInstanc
119
119
 
120
120
  // package.json
121
121
  var name = "@razaman2/reactive-view";
122
- var version = "0.0.24";
122
+ var version = "0.0.26";
123
123
 
124
124
  // src/ReactiveView.ts
125
125
  var setup = {
@@ -132,9 +132,7 @@ var ReactiveView_default = {
132
132
  ReactiveView: {
133
133
  default: true
134
134
  },
135
- instance: {
136
- default: ref()
137
- },
135
+ instance: {},
138
136
  notifications: Object,
139
137
  subscriptions: Object,
140
138
  beforeSetData: Function,
@@ -260,11 +258,11 @@ var ReactiveView_default = {
260
258
  const component = ref({ parent: { self: instance.proxy }, self: { template, model, isValid } });
261
259
  if (access(component).ReactiveView) {
262
260
  component.value = [access(component)].reduce((options, parent) => {
263
- var _a2;
261
+ var _a2, _b2;
264
262
  while (parent) {
265
263
  if (typeof parent.setup === "function") {
266
- options = { parent: options, self: (_a2 = parent.setup(component, options)) != null ? _a2 : {} };
267
- console.log("log options:", options);
264
+ const ups = parent.setup(component, options);
265
+ options = { parent: options, self: (_b2 = (_a2 = ups.value) != null ? _a2 : ups) != null ? _b2 : {} };
268
266
  if (access(parent.$parent).ReactiveView) {
269
267
  break;
270
268
  } else {
@@ -277,9 +275,9 @@ var ReactiveView_default = {
277
275
  return options;
278
276
  }, component.value);
279
277
  }
280
- console.log("component before:", component.value);
281
- props.instance.value = component.value;
282
- console.log("component after:", component.value, props.instance.value);
278
+ if (props.instance) {
279
+ props.instance.value = component.value;
280
+ }
283
281
  return (vue) => {
284
282
  if (ready.value) {
285
283
  return access(component).template(component, vue);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@razaman2/reactive-view",
3
- "version": "0.0.24",
3
+ "version": "0.0.26",
4
4
  "description": "This library enables you to build vue apps in an object oriented way. It provides a convenient approach to extend and override ui components. It provides a built in eventing system along with component data management.",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",