@supermousejs/vue 2.1.1 → 2.2.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.
- package/CHANGELOG.md +73 -57
- package/LICENSE.md +21 -21
- package/README.md +36 -39
- package/dist/index.d.ts +1 -24
- package/dist/index.mjs +3 -1
- package/dist/vue/src/index.d.ts +18 -0
- package/dist/vue/src/index.d.ts.map +1 -0
- package/package.json +3 -3
- package/src/index.ts +61 -56
- package/tsconfig.json +3 -14
- package/vite.config.ts +34 -23
package/CHANGELOG.md
CHANGED
|
@@ -1,57 +1,73 @@
|
|
|
1
|
-
# @supermousejs/vue
|
|
2
|
-
|
|
3
|
-
## 2.
|
|
4
|
-
|
|
5
|
-
###
|
|
6
|
-
|
|
7
|
-
-
|
|
8
|
-
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
- Updated
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
- Updated dependencies
|
|
46
|
-
- @supermousejs/core@2.0.
|
|
47
|
-
|
|
48
|
-
## 2.0.
|
|
49
|
-
|
|
50
|
-
###
|
|
51
|
-
|
|
52
|
-
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
1
|
+
# @supermousejs/vue
|
|
2
|
+
|
|
3
|
+
## 2.2.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 9fe1a7b: - Implemented idiomatic approach to using supermouse/utils
|
|
8
|
+
- Rewrote `applyStyles`, `setTransform` and `setStyles` to share a global cache registry
|
|
9
|
+
|
|
10
|
+
### Patch Changes
|
|
11
|
+
|
|
12
|
+
- 6d70c18: remove legacy package and update supermouse domain in readme
|
|
13
|
+
- 14fb5b6: Updated tsconfig to be reference-compliant with core, utils and zoetrope when required
|
|
14
|
+
- Updated dependencies [6d70c18]
|
|
15
|
+
- Updated dependencies [2590af3]
|
|
16
|
+
- Updated dependencies [14fb5b6]
|
|
17
|
+
- @supermousejs/core@2.1.0
|
|
18
|
+
|
|
19
|
+
## 2.1.1
|
|
20
|
+
|
|
21
|
+
### Patch Changes
|
|
22
|
+
|
|
23
|
+
- 67f771b: Add relevant npm metadata to package.json file
|
|
24
|
+
- Updated dependencies [67f771b]
|
|
25
|
+
- @supermousejs/core@2.0.5
|
|
26
|
+
|
|
27
|
+
## 2.1.0
|
|
28
|
+
|
|
29
|
+
### Minor Changes
|
|
30
|
+
|
|
31
|
+
- 0a1652d: fixed build architecture and updated plugin metadata
|
|
32
|
+
|
|
33
|
+
## 2.0.4
|
|
34
|
+
|
|
35
|
+
### Patch Changes
|
|
36
|
+
|
|
37
|
+
- 993dc67: Updated supemousejs packages with proper author, license and url descriptors to repo
|
|
38
|
+
- Updated dependencies [993dc67]
|
|
39
|
+
- @supermousejs/core@2.0.4
|
|
40
|
+
|
|
41
|
+
## 2.0.3
|
|
42
|
+
|
|
43
|
+
### Patch Changes
|
|
44
|
+
|
|
45
|
+
- Updated dependencies
|
|
46
|
+
- @supermousejs/core@2.0.3
|
|
47
|
+
|
|
48
|
+
## 2.0.2
|
|
49
|
+
|
|
50
|
+
### Patch Changes
|
|
51
|
+
|
|
52
|
+
- ae219a0: Update READMEs with correct link to documentation
|
|
53
|
+
- Updated dependencies [ae219a0]
|
|
54
|
+
- @supermousejs/core@2.0.2
|
|
55
|
+
|
|
56
|
+
## 2.0.1
|
|
57
|
+
|
|
58
|
+
### Patch Changes
|
|
59
|
+
|
|
60
|
+
- Add minimal README.md files to packages
|
|
61
|
+
- Updated dependencies
|
|
62
|
+
- @supermousejs/core@2.0.1
|
|
63
|
+
|
|
64
|
+
## 2.0.0
|
|
65
|
+
|
|
66
|
+
### Major Changes
|
|
67
|
+
|
|
68
|
+
- Initial v2.0.0 release
|
|
69
|
+
|
|
70
|
+
### Patch Changes
|
|
71
|
+
|
|
72
|
+
- Updated dependencies
|
|
73
|
+
- @supermousejs/core@2.0.0
|
package/LICENSE.md
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2025 Sijibomi Olusunmbola
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 Sijibomi Olusunmbola
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,39 +1,36 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
import {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
<
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
## Documentation
|
|
38
|
-
|
|
39
|
-
Full documentation and interactive playground available at [supermouse](https://supermouse.vercel.app) or [check out the repo](https://github.com/Whitestar14/supermouse-js).
|
|
1
|
+
# @supermousejs/vue
|
|
2
|
+
|
|
3
|
+
Vue 3 integration for Supermouse.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
pnpm add @supermousejs/vue @supermousejs/core
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
**In `App.vue` (Root):**
|
|
14
|
+
|
|
15
|
+
```vue
|
|
16
|
+
<script setup>
|
|
17
|
+
import { provideSupermouse } from "@supermousejs/vue";
|
|
18
|
+
import { Dot } from "@supermousejs/dot";
|
|
19
|
+
|
|
20
|
+
provideSupermouse({ smoothness: 0.15 }, [Dot({ size: 8 })]);
|
|
21
|
+
</script>
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
**In Components:**
|
|
25
|
+
|
|
26
|
+
```vue
|
|
27
|
+
<script setup>
|
|
28
|
+
import { useSupermouse } from "@supermousejs/vue";
|
|
29
|
+
|
|
30
|
+
const mouse = useSupermouse(); // Returns Ref<Supermouse | null>
|
|
31
|
+
</script>
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Documentation
|
|
35
|
+
|
|
36
|
+
Full documentation and interactive playground available at [supermouse](https://supermouse.js.org) or [check out the repo](https://github.com/Whitestar14/supermouse-js).
|
package/dist/index.d.ts
CHANGED
|
@@ -1,24 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import { Ref } from 'vue';
|
|
3
|
-
import { Supermouse } from '../../core/src/index.ts';
|
|
4
|
-
import { SupermouseOptions } from '../../core/src/index.ts';
|
|
5
|
-
import { SupermousePlugin } from '../../core/src/index.ts';
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* Initializes a Supermouse instance, handles its lifecycle, and provides it to the component tree.
|
|
9
|
-
* Use this in your root component (e.g., App.vue).
|
|
10
|
-
*
|
|
11
|
-
* @param options Core configuration options
|
|
12
|
-
* @param plugins Array of plugins to install immediately
|
|
13
|
-
*/
|
|
14
|
-
export declare function provideSupermouse(options?: SupermouseOptions, plugins?: SupermousePlugin[]): Ref<Supermouse | null>;
|
|
15
|
-
|
|
16
|
-
export declare const SupermouseKey: InjectionKey<Ref<Supermouse | null>>;
|
|
17
|
-
|
|
18
|
-
/**
|
|
19
|
-
* Injects the global Supermouse instance from a parent component.
|
|
20
|
-
* Returns a Ref that resolves to the instance once mounted.
|
|
21
|
-
*/
|
|
22
|
-
export declare function useSupermouse(): Ref<Supermouse | null>;
|
|
23
|
-
|
|
24
|
-
export { }
|
|
1
|
+
export * from "./vue/src/index";
|
package/dist/index.mjs
CHANGED
|
@@ -13,7 +13,9 @@ function f(o = {}, s = []) {
|
|
|
13
13
|
}
|
|
14
14
|
function v() {
|
|
15
15
|
const o = m(r);
|
|
16
|
-
return o || (console.warn(
|
|
16
|
+
return o || (console.warn(
|
|
17
|
+
"[Supermouse] No instance provided. Ensure provideSupermouse() is called in a parent component."
|
|
18
|
+
), u(null));
|
|
17
19
|
}
|
|
18
20
|
export {
|
|
19
21
|
r as SupermouseKey,
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Ref, InjectionKey } from 'vue';
|
|
2
|
+
import { Supermouse, SupermouseOptions, SupermousePlugin } from '../../core/src';
|
|
3
|
+
export declare const SupermouseKey: InjectionKey<Ref<Supermouse | null>>;
|
|
4
|
+
/**
|
|
5
|
+
* Initializes a Supermouse instance, handles its lifecycle, and provides it to the component tree.
|
|
6
|
+
* Use this in your root component (e.g., App.vue).
|
|
7
|
+
*
|
|
8
|
+
* @param options Core configuration options
|
|
9
|
+
* @param plugins Array of plugins to install immediately
|
|
10
|
+
*/
|
|
11
|
+
export declare function provideSupermouse(options?: SupermouseOptions, plugins?: SupermousePlugin[]): Ref<Supermouse | null>;
|
|
12
|
+
/**
|
|
13
|
+
* Injects the global Supermouse instance from a parent component.
|
|
14
|
+
* @returns A Ref containing the Supermouse instance or null if not provided.
|
|
15
|
+
* @warn Make sure to call provideSupermouse() in a parent component, otherwise this will return null.
|
|
16
|
+
*/
|
|
17
|
+
export declare function useSupermouse(): Ref<Supermouse | null>;
|
|
18
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAML,KAAK,GAAG,EACR,KAAK,YAAY,EAClB,MAAM,KAAK,CAAC;AACb,OAAO,EAAE,UAAU,EAAE,KAAK,iBAAiB,EAAE,KAAK,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAE/F,eAAO,MAAM,aAAa,EAAE,YAAY,CAAC,GAAG,CAAC,UAAU,GAAG,IAAI,CAAC,CAAwB,CAAC;AAExF;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAC/B,OAAO,GAAE,iBAAsB,EAC/B,OAAO,GAAE,gBAAgB,EAAO,GAC/B,GAAG,CAAC,UAAU,GAAG,IAAI,CAAC,CAqBxB;AAED;;;;GAIG;AACH,wBAAgB,aAAa,IAAI,GAAG,CAAC,UAAU,GAAG,IAAI,CAAC,CAStD"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@supermousejs/vue",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.2.0",
|
|
4
4
|
"main": "dist/index.umd.js",
|
|
5
5
|
"module": "dist/index.mjs",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -9,11 +9,11 @@
|
|
|
9
9
|
"license": "MIT",
|
|
10
10
|
"peerDependencies": {
|
|
11
11
|
"vue": "^3.2.0",
|
|
12
|
-
"@supermousejs/core": "2.0
|
|
12
|
+
"@supermousejs/core": "2.1.0"
|
|
13
13
|
},
|
|
14
14
|
"devDependencies": {
|
|
15
15
|
"vue": "^3.2.0",
|
|
16
|
-
"@supermousejs/core": "2.0
|
|
16
|
+
"@supermousejs/core": "2.1.0"
|
|
17
17
|
},
|
|
18
18
|
"repository": {
|
|
19
19
|
"type": "git",
|
package/src/index.ts
CHANGED
|
@@ -1,56 +1,61 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
1
|
+
import {
|
|
2
|
+
onMounted,
|
|
3
|
+
onUnmounted,
|
|
4
|
+
provide,
|
|
5
|
+
inject,
|
|
6
|
+
shallowRef,
|
|
7
|
+
type Ref,
|
|
8
|
+
type InjectionKey
|
|
9
|
+
} from "vue";
|
|
10
|
+
import { Supermouse, type SupermouseOptions, type SupermousePlugin } from "@supermousejs/core";
|
|
11
|
+
|
|
12
|
+
export const SupermouseKey: InjectionKey<Ref<Supermouse | null>> = Symbol("Supermouse");
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Initializes a Supermouse instance, handles its lifecycle, and provides it to the component tree.
|
|
16
|
+
* Use this in your root component (e.g., App.vue).
|
|
17
|
+
*
|
|
18
|
+
* @param options Core configuration options
|
|
19
|
+
* @param plugins Array of plugins to install immediately
|
|
20
|
+
*/
|
|
21
|
+
export function provideSupermouse(
|
|
22
|
+
options: SupermouseOptions = {},
|
|
23
|
+
plugins: SupermousePlugin[] = []
|
|
24
|
+
): Ref<Supermouse | null> {
|
|
25
|
+
const instance = shallowRef<Supermouse | null>(null);
|
|
26
|
+
|
|
27
|
+
onMounted(() => {
|
|
28
|
+
if (instance.value) return;
|
|
29
|
+
|
|
30
|
+
const mouse = new Supermouse(options);
|
|
31
|
+
plugins.forEach((p) => mouse.use(p));
|
|
32
|
+
instance.value = mouse;
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
onUnmounted(() => {
|
|
36
|
+
if (instance.value) {
|
|
37
|
+
instance.value.destroy();
|
|
38
|
+
instance.value = null;
|
|
39
|
+
}
|
|
40
|
+
});
|
|
41
|
+
|
|
42
|
+
provide(SupermouseKey, instance);
|
|
43
|
+
|
|
44
|
+
return instance;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Injects the global Supermouse instance from a parent component.
|
|
49
|
+
* @returns A Ref containing the Supermouse instance or null if not provided.
|
|
50
|
+
* @warn Make sure to call provideSupermouse() in a parent component, otherwise this will return null.
|
|
51
|
+
*/
|
|
52
|
+
export function useSupermouse(): Ref<Supermouse | null> {
|
|
53
|
+
const instance = inject(SupermouseKey);
|
|
54
|
+
if (!instance) {
|
|
55
|
+
console.warn(
|
|
56
|
+
"[Supermouse] No instance provided. Ensure provideSupermouse() is called in a parent component."
|
|
57
|
+
);
|
|
58
|
+
return shallowRef(null);
|
|
59
|
+
}
|
|
60
|
+
return instance;
|
|
61
|
+
}
|
package/tsconfig.json
CHANGED
|
@@ -1,15 +1,4 @@
|
|
|
1
1
|
{
|
|
2
|
-
"extends": "../../tsconfig.
|
|
3
|
-
"include": [
|
|
4
|
-
|
|
5
|
-
],
|
|
6
|
-
"compilerOptions": {
|
|
7
|
-
"outDir": "dist",
|
|
8
|
-
"baseUrl": ".",
|
|
9
|
-
"paths": {
|
|
10
|
-
"@supermousejs/core": [
|
|
11
|
-
"../core/src/index.ts"
|
|
12
|
-
]
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
}
|
|
2
|
+
"extends": "../../tsconfig.framework.json",
|
|
3
|
+
"include": ["src"]
|
|
4
|
+
}
|
package/vite.config.ts
CHANGED
|
@@ -1,23 +1,34 @@
|
|
|
1
|
-
import { defineConfig } from
|
|
2
|
-
import dts from
|
|
3
|
-
import path from
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
1
|
+
import { defineConfig } from "vite";
|
|
2
|
+
import dts from "vite-plugin-dts";
|
|
3
|
+
import path from "path";
|
|
4
|
+
import { writeFileSync } from "fs";
|
|
5
|
+
|
|
6
|
+
export default defineConfig({
|
|
7
|
+
build: {
|
|
8
|
+
lib: {
|
|
9
|
+
entry: path.resolve(__dirname, "src/index.ts"),
|
|
10
|
+
name: "SupermouseVue",
|
|
11
|
+
fileName: (format) => (format === "es" ? "index.mjs" : "index.umd.js")
|
|
12
|
+
},
|
|
13
|
+
rollupOptions: {
|
|
14
|
+
external: ["vue", "@supermousejs/core"],
|
|
15
|
+
output: {
|
|
16
|
+
globals: {
|
|
17
|
+
vue: "Vue",
|
|
18
|
+
"@supermousejs/core": "SupermouseCore"
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
plugins: [
|
|
24
|
+
dts({ rollupTypes: false }),
|
|
25
|
+
{
|
|
26
|
+
name: "dts-wrapper",
|
|
27
|
+
apply: "build",
|
|
28
|
+
closeBundle: async () => {
|
|
29
|
+
const wrapperContent = `export * from "./vue/src/index";\n`;
|
|
30
|
+
writeFileSync(path.resolve(__dirname, "dist/index.d.ts"), wrapperContent);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
]
|
|
34
|
+
});
|