Skip to content

Commit 80d1215

Browse files
committed
chore: update dependencies
1 parent 28ff060 commit 80d1215

File tree

11 files changed

+748
-254
lines changed

11 files changed

+748
-254
lines changed

README.md

-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@
3939

4040
[bundlePhobiaBadge]:https://badgen.net/bundlephobia/minzip/@vueblocks/vue-use-core
4141
[bundlePhobiaUrl]:https://bundlephobia.com/result?p=@vueblocks/vue-use-core
42-
</p>
4342

4443
## ✨ Features
4544

package.json

+4-27
Original file line numberDiff line numberDiff line change
@@ -15,46 +15,23 @@
1515
},
1616
"sideEffects": false,
1717
"devDependencies": {
18-
"@juggle/resize-observer": "^3.3.0",
19-
"@rollup/plugin-replace": "^2.4.1",
18+
"@rollup/plugin-replace": "^3.0.0",
2019
"@types/jest": "^26.0.20",
21-
"@types/keymaster": "^1.6.28",
22-
"@types/lodash.clonedeep": "^4.5.6",
23-
"@types/lodash.debounce": "^4.0.6",
24-
"@types/lodash.throttle": "^4.1.6",
25-
"@types/node": "^14.14.32",
26-
"@vue/test-utils": "^1.1.3",
27-
"axios": "^0.21.1",
28-
"color2k": "^1.2.4",
20+
"@types/node": "^16.4.0",
21+
"@vue/test-utils": "^1.2.1",
2922
"esbuild": "^0.8.29",
3023
"esbuild-register": "^1.2.1",
3124
"eslint": "^7.17.0",
3225
"eslint-plugin-jest": "^24.1.3",
3326
"esm": "^3.2.25",
3427
"jest": "^26.6.3",
35-
"keymaster": "^1.6.2",
3628
"lerna": "^3.22.1",
37-
"lodash.clonedeep": "^4.5.0",
38-
"lodash.debounce": "^4.0.8",
39-
"lodash.throttle": "^4.1.1",
40-
"mitt": "^2.1.0",
41-
"number-precision": "^1.5.0",
4229
"rollup": "^2.40.0",
4330
"rollup-plugin-dts": "^2.0.1",
4431
"rollup-plugin-filesize": "^9.1.1",
4532
"rollup-plugin-terser": "^7.0.2",
4633
"rollup-plugin-typescript2": "^0.29.0",
47-
"screenfull": "^5.1.0",
48-
"stateshot": "^1.3.3",
4934
"ts-jest": "^26.5.3",
50-
"typescript": "^4.2.3",
51-
"vue": "^2.6.12",
52-
"vue-template-compiler": "^2.6.12",
53-
"vue3": "npm:vue@3",
54-
"vuex": "^3.6.2"
55-
},
56-
"dependencies": {
57-
"@vue/composition-api": "^1.0.0-rc.3",
58-
"vue-demi": "^0.7.1"
35+
"typescript": "^4.2.3"
5936
}
6037
}

packages/axios/package.json

+18-4
Original file line numberDiff line numberDiff line change
@@ -28,15 +28,29 @@
2828
"author": "xiaoluoboding<https://github.com/xiaoluoboding>",
2929
"license": "MIT",
3030
"sideEffects": false,
31+
"peerDependenciesMeta": {
32+
"@vue/composition-api": {
33+
"optional": true
34+
}
35+
},
3136
"peerDependencies": {
32-
"axios": "^0.21.0"
37+
"@vue/composition-api": "^1.2.4",
38+
"axios": "^0.21.0",
39+
"vue": "^2.6.14 || ^3.2.0"
3340
},
3441
"dependencies": {
35-
"@vue/composition-api": "^1.0.0-rc.3",
42+
"@vue/composition-api": "^1.2.4",
43+
"axios": "^0.24.0",
3644
"lodash.debounce": "^4.0.8",
3745
"lodash.throttle": "^4.1.1",
38-
"vue-demi": "^0.7.1",
39-
"axios": "^0.21.1"
46+
"vue-demi": "^0.11.4"
47+
},
48+
"devDependencies": {
49+
"@types/lodash.debounce": "^4.0.6",
50+
"@types/lodash.throttle": "^4.1.6",
51+
"@vue/compiler-sfc": "^3.2.20",
52+
"vue": "^3.2.20",
53+
"vue2": "npm:vue@2"
4054
},
4155
"gitHead": "19fec27b41f71b70a73f0afd37180c39bb362827"
4256
}

packages/axios/yarn.lock

+223
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,223 @@
1+
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
2+
# yarn lockfile v1
3+
4+
5+
"@babel/parser@^7.15.0":
6+
version "7.15.8"
7+
resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.15.8.tgz#7bacdcbe71bdc3ff936d510c15dcea7cf0b99016"
8+
integrity sha512-BRYa3wcQnjS/nqI8Ac94pYYpJfojHVvVXJ97+IDCImX4Jc8W8Xv1+47enbruk+q1etOpsQNwnfFcNGw+gtPGxA==
9+
10+
"@types/lodash.debounce@^4.0.6":
11+
version "4.0.6"
12+
resolved "https://registry.yarnpkg.com/@types/lodash.debounce/-/lodash.debounce-4.0.6.tgz#c5a2326cd3efc46566c47e4c0aa248dc0ee57d60"
13+
integrity sha512-4WTmnnhCfDvvuLMaF3KV4Qfki93KebocUF45msxhYyjMttZDQYzHkO639ohhk8+oco2cluAFL3t5+Jn4mleylQ==
14+
dependencies:
15+
"@types/lodash" "*"
16+
17+
"@types/lodash.throttle@^4.1.6":
18+
version "4.1.6"
19+
resolved "https://registry.yarnpkg.com/@types/lodash.throttle/-/lodash.throttle-4.1.6.tgz#f5ba2c22244ee42ff6c2c49e614401a870c1009c"
20+
integrity sha512-/UIH96i/sIRYGC60NoY72jGkCJtFN5KVPhEMMMTjol65effe1gPn0tycJqV5tlSwMTzX8FqzB5yAj0rfGHTPNg==
21+
dependencies:
22+
"@types/lodash" "*"
23+
24+
"@types/lodash@*":
25+
version "4.14.176"
26+
resolved "https://registry.yarnpkg.com/@types/lodash/-/lodash-4.14.176.tgz#641150fc1cda36fbfa329de603bbb175d7ee20c0"
27+
integrity sha512-xZmuPTa3rlZoIbtDUyJKZQimJV3bxCmzMIO2c9Pz9afyDro6kr7R79GwcB6mRhuoPmV2p1Vb66WOJH7F886WKQ==
28+
29+
"@vue/compiler-core@3.2.20":
30+
version "3.2.20"
31+
resolved "https://registry.yarnpkg.com/@vue/compiler-core/-/compiler-core-3.2.20.tgz#af5a3c5237818835b0d0be837eb5885a8d21c160"
32+
integrity sha512-vcEXlKXoPwBXFP5aUTHN9GTZaDfwCofa9Yu9bbW2C5O/QSa9Esdt7OG4+0RRd3EHEMxUvEdj4RZrd/KpQeiJbA==
33+
dependencies:
34+
"@babel/parser" "^7.15.0"
35+
"@vue/shared" "3.2.20"
36+
estree-walker "^2.0.2"
37+
source-map "^0.6.1"
38+
39+
"@vue/compiler-dom@3.2.20":
40+
version "3.2.20"
41+
resolved "https://registry.yarnpkg.com/@vue/compiler-dom/-/compiler-dom-3.2.20.tgz#8e0ef354449c0faf41519b00bfc2045eae01dcb5"
42+
integrity sha512-QnI77ec/JtV7R0YBbcVayYTDCRcI9OCbxiUQK6izVyqQO0658n0zQuoNwe+bYgtqnvGAIqTR3FShTd5y4oOjdg==
43+
dependencies:
44+
"@vue/compiler-core" "3.2.20"
45+
"@vue/shared" "3.2.20"
46+
47+
"@vue/compiler-sfc@3.2.20", "@vue/compiler-sfc@^3.2.20":
48+
version "3.2.20"
49+
resolved "https://registry.yarnpkg.com/@vue/compiler-sfc/-/compiler-sfc-3.2.20.tgz#2d7668e76f066c566dd7c09c15c9acce4e876e0a"
50+
integrity sha512-03aZo+6tQKiFLfunHKSPZvdK4Jsn/ftRCyaro8AQIWkuxJbvSosbKK6HTTn+D2c3nPScG155akJoxKENw7rftQ==
51+
dependencies:
52+
"@babel/parser" "^7.15.0"
53+
"@vue/compiler-core" "3.2.20"
54+
"@vue/compiler-dom" "3.2.20"
55+
"@vue/compiler-ssr" "3.2.20"
56+
"@vue/ref-transform" "3.2.20"
57+
"@vue/shared" "3.2.20"
58+
estree-walker "^2.0.2"
59+
magic-string "^0.25.7"
60+
postcss "^8.1.10"
61+
source-map "^0.6.1"
62+
63+
"@vue/compiler-ssr@3.2.20":
64+
version "3.2.20"
65+
resolved "https://registry.yarnpkg.com/@vue/compiler-ssr/-/compiler-ssr-3.2.20.tgz#9cceb6261d9932cb5568202610c1c28f86c5e521"
66+
integrity sha512-rzzVVYivm+EjbfiGQvNeyiYZWzr6Hkej97RZLZvcumacQlnKv9176Xo9rRyeWwFbBlxmtNdrVMslRXtipMXk2w==
67+
dependencies:
68+
"@vue/compiler-dom" "3.2.20"
69+
"@vue/shared" "3.2.20"
70+
71+
"@vue/composition-api@^1.2.4":
72+
version "1.2.4"
73+
resolved "https://registry.yarnpkg.com/@vue/composition-api/-/composition-api-1.2.4.tgz#4befcefc0e1c570fd0879a2d8b8f901f3a4e35d0"
74+
integrity sha512-8LVV6O4slsroBhRKxly3em5H3D5Q+ggPG75lcilh5MfLGs69LEdwm6dKhSOXtQoSyMGF4Rq30E4DcouopM8Rxg==
75+
dependencies:
76+
tslib "^2.3.0"
77+
78+
"@vue/reactivity@3.2.20":
79+
version "3.2.20"
80+
resolved "https://registry.yarnpkg.com/@vue/reactivity/-/reactivity-3.2.20.tgz#81fe1c368e7f20bc0ec1dec1045bbee253582de8"
81+
integrity sha512-nSmoLojUTk+H8HNTAkrUduB4+yIUBK2HPihJo2uXVSH4Spry6oqN6lFzE5zpLK+F27Sja+UqR9R1+/kIOsHV5w==
82+
dependencies:
83+
"@vue/shared" "3.2.20"
84+
85+
"@vue/ref-transform@3.2.20":
86+
version "3.2.20"
87+
resolved "https://registry.yarnpkg.com/@vue/ref-transform/-/ref-transform-3.2.20.tgz#2a59ec90caf8e5c7336776a0900bff0a8b81c090"
88+
integrity sha512-Y42d3PGlYZ1lXcF3dbd3+qU/C/a3wYEZ949fyOI5ptzkjDWlkfU6vn74fmOjsLjEcjs10BXK2qO99FqQIK2r1Q==
89+
dependencies:
90+
"@babel/parser" "^7.15.0"
91+
"@vue/compiler-core" "3.2.20"
92+
"@vue/shared" "3.2.20"
93+
estree-walker "^2.0.2"
94+
magic-string "^0.25.7"
95+
96+
"@vue/runtime-core@3.2.20":
97+
version "3.2.20"
98+
resolved "https://registry.yarnpkg.com/@vue/runtime-core/-/runtime-core-3.2.20.tgz#8f63e956a3f88fb772541443c45a7701211012cb"
99+
integrity sha512-d1xfUGhZPfiZzAN7SatStD4vRtT8deJSXib2+Cz3x0brjMWKxe32asQc154FF1E2fFgMCHtnfd4A90bQEzV4GQ==
100+
dependencies:
101+
"@vue/reactivity" "3.2.20"
102+
"@vue/shared" "3.2.20"
103+
104+
"@vue/runtime-dom@3.2.20":
105+
version "3.2.20"
106+
resolved "https://registry.yarnpkg.com/@vue/runtime-dom/-/runtime-dom-3.2.20.tgz#8aa56ae6c30f9cd4a71ca0e9ec3c4bdc67148d15"
107+
integrity sha512-4TCvZMLhESWCFHFYgqN4QmMA/onnINAlUovhopjlS8ST27G1A8Z0tyxPzLoXLa+b5JrOpbMPheEMPvdKExTJig==
108+
dependencies:
109+
"@vue/runtime-core" "3.2.20"
110+
"@vue/shared" "3.2.20"
111+
csstype "^2.6.8"
112+
113+
"@vue/server-renderer@3.2.20":
114+
version "3.2.20"
115+
resolved "https://registry.yarnpkg.com/@vue/server-renderer/-/server-renderer-3.2.20.tgz#705e07ae9425132b2b6227d308a51a13f4d4ec81"
116+
integrity sha512-viIbZGep9XabnrRcaxWIi00cOh1x21QYm2upIL5W0zqzTJ54VdTzpI+zi1osNp+VfRQDTHpV2U7H3Kn4ljYJvg==
117+
dependencies:
118+
"@vue/compiler-ssr" "3.2.20"
119+
"@vue/shared" "3.2.20"
120+
121+
"@vue/shared@3.2.20":
122+
version "3.2.20"
123+
resolved "https://registry.yarnpkg.com/@vue/shared/-/shared-3.2.20.tgz#53746961f731a8ea666e3316271e944238dc31db"
124+
integrity sha512-FbpX+hD5BvXCQerEYO7jtAGHlhAkhTQ4KIV73kmLWNlawWhTiVuQxizgVb0BOkX5oG9cIRZ42EG++d/k/Efp0w==
125+
126+
axios@^0.24.0:
127+
version "0.24.0"
128+
resolved "https://registry.yarnpkg.com/axios/-/axios-0.24.0.tgz#804e6fa1e4b9c5288501dd9dff56a7a0940d20d6"
129+
integrity sha512-Q6cWsys88HoPgAaFAVUb0WpPk0O8iTeisR9IMqy9G8AbO4NlpVknrnQS03zzF9PGAWgO3cgletO3VjV/P7VztA==
130+
dependencies:
131+
follow-redirects "^1.14.4"
132+
133+
csstype@^2.6.8:
134+
version "2.6.18"
135+
resolved "https://registry.yarnpkg.com/csstype/-/csstype-2.6.18.tgz#980a8b53085f34af313410af064f2bd241784218"
136+
integrity sha512-RSU6Hyeg14am3Ah4VZEmeX8H7kLwEEirXe6aU2IPfKNvhXwTflK5HQRDNI0ypQXoqmm+QPyG2IaPuQE5zMwSIQ==
137+
138+
estree-walker@^2.0.2:
139+
version "2.0.2"
140+
resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-2.0.2.tgz#52f010178c2a4c117a7757cfe942adb7d2da4cac"
141+
integrity sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==
142+
143+
follow-redirects@^1.14.4:
144+
version "1.14.4"
145+
resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.14.4.tgz#838fdf48a8bbdd79e52ee51fb1c94e3ed98b9379"
146+
integrity sha512-zwGkiSXC1MUJG/qmeIFH2HBJx9u0V46QGUe3YR1fXG8bXQxq7fLj0RjLZQ5nubr9qNJUZrH+xUcwXEoXNpfS+g==
147+
148+
lodash.debounce@^4.0.8:
149+
version "4.0.8"
150+
resolved "https://registry.yarnpkg.com/lodash.debounce/-/lodash.debounce-4.0.8.tgz#82d79bff30a67c4005ffd5e2515300ad9ca4d7af"
151+
integrity sha1-gteb/zCmfEAF/9XiUVMArZyk168=
152+
153+
lodash.throttle@^4.1.1:
154+
version "4.1.1"
155+
resolved "https://registry.yarnpkg.com/lodash.throttle/-/lodash.throttle-4.1.1.tgz#c23e91b710242ac70c37f1e1cda9274cc39bf2f4"
156+
integrity sha1-wj6RtxAkKscMN/HhzaknTMOb8vQ=
157+
158+
magic-string@^0.25.7:
159+
version "0.25.7"
160+
resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.25.7.tgz#3f497d6fd34c669c6798dcb821f2ef31f5445051"
161+
integrity sha512-4CrMT5DOHTDk4HYDlzmwu4FVCcIYI8gauveasrdCu2IKIFOJ3f0v/8MDGJCDL9oD2ppz/Av1b0Nj345H9M+XIA==
162+
dependencies:
163+
sourcemap-codec "^1.4.4"
164+
165+
nanoid@^3.1.30:
166+
version "3.1.30"
167+
resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.1.30.tgz#63f93cc548d2a113dc5dfbc63bfa09e2b9b64362"
168+
integrity sha512-zJpuPDwOv8D2zq2WRoMe1HsfZthVewpel9CAvTfc/2mBD1uUT/agc5f7GHGWXlYkFvi1mVxe4IjvP2HNrop7nQ==
169+
170+
picocolors@^1.0.0:
171+
version "1.0.0"
172+
resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c"
173+
integrity sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==
174+
175+
postcss@^8.1.10:
176+
version "8.3.11"
177+
resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.3.11.tgz#c3beca7ea811cd5e1c4a3ec6d2e7599ef1f8f858"
178+
integrity sha512-hCmlUAIlUiav8Xdqw3Io4LcpA1DOt7h3LSTAC4G6JGHFFaWzI6qvFt9oilvl8BmkbBRX1IhM90ZAmpk68zccQA==
179+
dependencies:
180+
nanoid "^3.1.30"
181+
picocolors "^1.0.0"
182+
source-map-js "^0.6.2"
183+
184+
source-map-js@^0.6.2:
185+
version "0.6.2"
186+
resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-0.6.2.tgz#0bb5de631b41cfbda6cfba8bd05a80efdfd2385e"
187+
integrity sha512-/3GptzWzu0+0MBQFrDKzw/DvvMTUORvgY6k6jd/VS6iCR4RDTKWH6v6WPwQoUO8667uQEf9Oe38DxAYWY5F/Ug==
188+
189+
source-map@^0.6.1:
190+
version "0.6.1"
191+
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263"
192+
integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==
193+
194+
sourcemap-codec@^1.4.4:
195+
version "1.4.8"
196+
resolved "https://registry.yarnpkg.com/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz#ea804bd94857402e6992d05a38ef1ae35a9ab4c4"
197+
integrity sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==
198+
199+
tslib@^2.3.0:
200+
version "2.3.1"
201+
resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.3.1.tgz#e8a335add5ceae51aa261d32a490158ef042ef01"
202+
integrity sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw==
203+
204+
vue-demi@^0.11.4:
205+
version "0.11.4"
206+
resolved "https://registry.yarnpkg.com/vue-demi/-/vue-demi-0.11.4.tgz#6101992fe4724cf5634018a16e953f3052e94e2a"
207+
integrity sha512-/3xFwzSykLW2HiiLie43a+FFgNOcokbBJ+fzvFXd0r2T8MYohqvphUyDQ8lbAwzQ3Dlcrb1c9ykifGkhSIAk6A==
208+
209+
"vue2@npm:vue@2":
210+
version "2.6.14"
211+
resolved "https://registry.yarnpkg.com/vue/-/vue-2.6.14.tgz#e51aa5250250d569a3fbad3a8a5a687d6036e235"
212+
integrity sha512-x2284lgYvjOMj3Za7kqzRcUSxBboHqtgRE2zlos1qWaOye5yUmHn42LB1250NJBLRwEcdrB0JRwyPTEPhfQjiQ==
213+
214+
vue@^3.2.20:
215+
version "3.2.20"
216+
resolved "https://registry.yarnpkg.com/vue/-/vue-3.2.20.tgz#940f8aa8bf3e3be78243ca582bad41fcd45ae3e6"
217+
integrity sha512-81JjEP4OGk9oO8+CU0h2nFPGgJBm9mNa3kdCX2k6FuRdrWrC+CNe+tOnuIeTg8EWwQuI+wwdra5Q7vSzp7p4Iw==
218+
dependencies:
219+
"@vue/compiler-dom" "3.2.20"
220+
"@vue/compiler-sfc" "3.2.20"
221+
"@vue/runtime-dom" "3.2.20"
222+
"@vue/server-renderer" "3.2.20"
223+
"@vue/shared" "3.2.20"

packages/core/package.json

+20-2
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,18 @@
2727
"author": "xiaoluoboding<https://github.com/xiaoluoboding>",
2828
"license": "MIT",
2929
"sideEffects": false,
30+
"peerDependenciesMeta": {
31+
"@vue/composition-api": {
32+
"optional": true
33+
}
34+
},
35+
"peerDependencies": {
36+
"@vue/composition-api": "^1.2.4",
37+
"vue": "^2.6.14 || ^3.2.0"
38+
},
3039
"dependencies": {
3140
"@juggle/resize-observer": "^3.2.0",
32-
"@vue/composition-api": "^1.0.0-rc.3",
41+
"@vue/composition-api": "^1.2.4",
3342
"color2k": "^1.2.4",
3443
"keymaster": "^1.6.2",
3544
"lodash.clonedeep": "^4.5.0",
@@ -38,7 +47,16 @@
3847
"number-precision": "^1.5.0",
3948
"screenfull": "^5.1.0",
4049
"stateshot": "^1.3.3",
41-
"vue-demi": "^0.7.1"
50+
"vue-demi": "^0.11.4"
51+
},
52+
"devDependencies": {
53+
"@types/keymaster": "^1.6.30",
54+
"@types/lodash.clonedeep": "^4.5.6",
55+
"@types/lodash.debounce": "^4.0.6",
56+
"@types/lodash.throttle": "^4.1.6",
57+
"@vue/compiler-sfc": "^3.2.20",
58+
"vue": "^3.2.20",
59+
"vue2": "npm:vue@2"
4260
},
4361
"gitHead": "19fec27b41f71b70a73f0afd37180c39bb362827"
4462
}

packages/core/useInstance/index.ts

+8-4
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,18 @@
1-
import { isVue3, getCurrentInstance } from 'vue-demi'
1+
import { getCurrentInstance, ComponentInternalInstance } from 'vue-demi'
2+
3+
export type InstanceProxy = ComponentInternalInstance['proxy'] | null
24

35
const useInstance = (): any => {
4-
const instance: any = getCurrentInstance()
6+
const instance = getCurrentInstance()
57

68
if (!instance) {
7-
console.error('`getCurrentInstance` only works during setup or Lifecycle Hooks')
9+
console.error(
10+
'`getCurrentInstance` only works during setup or Lifecycle Hooks'
11+
)
812
return null
913
}
1014

11-
return isVue3 ? instance.ctx : instance.proxy
15+
return instance.proxy
1216
}
1317

1418
export { useInstance }

packages/core/usePrecision/index.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,8 @@ import {
88
digitLength,
99
float2Fixed
1010
} from 'number-precision'
11-
import { ComputedRef } from 'vue-demi'
1211

13-
import { reactiveFn, } from '../utils'
12+
import { reactiveFn } from '../utils'
1413

1514
/**
1615
* `usePrecision` provide reactive methods to perform addition, subtraction, multiplication & division operations precisely.

0 commit comments

Comments
 (0)