@gradin/vue-utils 0.0.3 → 0.0.5
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.js +1 -0
- package/dist/types/index.d.ts +4 -0
- package/package.json +4 -3
package/dist/index.js
CHANGED
|
@@ -21,6 +21,7 @@ export const resetableReactive = (data) => {
|
|
|
21
21
|
});
|
|
22
22
|
return form;
|
|
23
23
|
};
|
|
24
|
+
export const gReactive = resetableReactive; // alias
|
|
24
25
|
/**
|
|
25
26
|
* Watch the route full path, and trigger callback when query / params change
|
|
26
27
|
* but don't trigger when route name change (move away to other page).
|
package/dist/types/index.d.ts
CHANGED
|
@@ -2,6 +2,10 @@ export declare const resetableReactive: <T extends object>(data: T) => T & {
|
|
|
2
2
|
reset: () => void;
|
|
3
3
|
set: (newValue: Partial<T>) => void;
|
|
4
4
|
};
|
|
5
|
+
export declare const gReactive: <T extends object>(data: T) => T & {
|
|
6
|
+
reset: () => void;
|
|
7
|
+
set: (newValue: Partial<T>) => void;
|
|
8
|
+
};
|
|
5
9
|
/**
|
|
6
10
|
* Watch the route full path, and trigger callback when query / params change
|
|
7
11
|
* but don't trigger when route name change (move away to other page).
|
package/package.json
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gradin/vue-utils",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.5",
|
|
4
4
|
"description": "Useful utilities for Vue projects.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
|
-
"types": "dist/index.d.ts",
|
|
7
|
+
"types": "dist/types/index.d.ts",
|
|
8
8
|
"scripts": {
|
|
9
9
|
"build": "tsc",
|
|
10
10
|
"lint": "eslint . --fix",
|
|
11
|
-
"publish": "npm run build
|
|
11
|
+
"publish": "npm run build",
|
|
12
|
+
"publish2": "npm run build && npm publish --access public"
|
|
12
13
|
},
|
|
13
14
|
"files": [
|
|
14
15
|
"dist"
|