create-mettle-app 1.6.0 → 1.7.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-mettle-app",
3
- "version": "1.6.0",
3
+ "version": "1.7.0",
4
4
  "license": "MIT",
5
5
  "author": "maomincoding",
6
6
  "bin": {
@@ -9,10 +9,10 @@
9
9
  },
10
10
  "devDependencies": {
11
11
  "vite": "^6.1.0",
12
- "vite-plugin-mettle": "^1.5.0",
12
+ "vite-plugin-mettle": "^1.7.0",
13
13
  "mettle-jsx-runtime": "^1.0.0"
14
14
  },
15
15
  "dependencies": {
16
- "mettle": "^1.5.0"
16
+ "mettle": "^1.7.0"
17
17
  }
18
18
  }
@@ -9,11 +9,11 @@
9
9
  },
10
10
  "devDependencies": {
11
11
  "vite": "^6.1.0",
12
- "vite-plugin-mettle": "^1.5.0",
12
+ "vite-plugin-mettle": "^1.7.0",
13
13
  "mettle-jsx-runtime": "^1.0.0"
14
14
  },
15
15
  "dependencies": {
16
- "mettle": "^1.5.0",
16
+ "mettle": "^1.7.0",
17
17
  "mettle-router": "^0.6.0"
18
18
  }
19
19
  }
@@ -10,11 +10,11 @@
10
10
  "devDependencies": {
11
11
  "typescript": "~5.7.2",
12
12
  "vite": "^6.1.0",
13
- "vite-plugin-mettle": "^1.5.0",
13
+ "vite-plugin-mettle": "^1.7.0",
14
14
  "mettle-jsx-runtime": "^1.0.0"
15
15
  },
16
16
  "dependencies": {
17
- "mettle": "^1.5.0",
17
+ "mettle": "^1.7.0",
18
18
  "mettle-router": "^0.6.0"
19
19
  }
20
20
  }
@@ -1,15 +1,6 @@
1
- import {
2
- signal as signalUntyped,
3
- produce as produceUntyped,
4
- batch,
5
- computed as computedUntyped,
6
- } from 'mettle';
1
+ import { signal, produce, batch, computed } from 'mettle';
7
2
  import { linkTo } from 'mettle-router';
8
3
 
9
- const signal = signalUntyped as any;
10
- const produce = produceUntyped as any;
11
- const computed = computedUntyped as any;
12
-
13
4
  export default function Home() {
14
5
  const msg = signal('hello');
15
6
  const arr = signal([1, 2]);
@@ -10,10 +10,10 @@
10
10
  "devDependencies": {
11
11
  "typescript": "~5.7.2",
12
12
  "vite": "^6.1.0",
13
- "vite-plugin-mettle": "^1.5.0",
13
+ "vite-plugin-mettle": "^1.7.0",
14
14
  "mettle-jsx-runtime": "^1.0.0"
15
15
  },
16
16
  "dependencies": {
17
- "mettle": "^1.5.0"
17
+ "mettle": "^1.7.0"
18
18
  }
19
19
  }
@@ -1,9 +1,6 @@
1
- import { signal as signalUntyped, produce as produceUntyped } from 'mettle';
1
+ import { signal, produce } from 'mettle';
2
2
  import style from '../style/list.module.css';
3
3
 
4
- const signal = signalUntyped as any;
5
- const produce = produceUntyped as any;
6
-
7
4
  export default function List() {
8
5
  const arr = signal([1, 2]);
9
6
  const count = signal(3);
@@ -1,9 +1,7 @@
1
- import { signal as signalUntyped } from 'mettle';
2
-
3
- const signal = signalUntyped as any;
1
+ import { signal } from 'mettle';
4
2
 
5
3
  export default function Home() {
6
- const count = signal(0);
4
+ const count: number = signal(0);
7
5
 
8
6
  function add() {
9
7
  count.value++;