@css-hooks/preact 1.5.1 → 1.5.3

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.
Files changed (2) hide show
  1. package/package.json +16 -10
  2. package/types/index.d.ts +1 -1
package/package.json CHANGED
@@ -1,21 +1,19 @@
1
1
  {
2
2
  "name": "@css-hooks/preact",
3
3
  "description": "CSS Hooks for Preact",
4
- "version": "1.5.1",
4
+ "version": "1.5.3",
5
5
  "author": "Nick Saunders",
6
6
  "dependencies": {
7
- "@css-hooks/core": "^1.5.1"
7
+ "@css-hooks/core": "^1.5.3"
8
8
  },
9
9
  "devDependencies": {
10
10
  "@tsconfig/strictest": "^2.0.1",
11
- "@types/jest": "^29.5.3",
12
11
  "@typescript-eslint/eslint-plugin": "^6.7.2",
13
12
  "@typescript-eslint/parser": "^6.7.2",
14
13
  "eslint": "^8.50.0",
15
- "jest": "^29.6.2",
16
14
  "preact": ">=10.0.0 <11.0.0",
17
15
  "rimraf": "^5.0.1",
18
- "ts-jest": "^29.1.1",
16
+ "ts-watch": "^1.0.8",
19
17
  "typescript": "^5.1.6"
20
18
  },
21
19
  "files": [
@@ -26,6 +24,7 @@
26
24
  "license": "MIT",
27
25
  "main": "cjs",
28
26
  "module": "esm",
27
+ "type": "module",
29
28
  "peerDependencies": {
30
29
  "preact": ">=10.0.0 <11.0.0"
31
30
  },
@@ -36,12 +35,19 @@
36
35
  "directory": "packages/preact"
37
36
  },
38
37
  "scripts": {
39
- "clean": "rimraf cjs esm types",
40
- "compile": "tsc",
41
- "lint": "eslint __tests__ src .*.*js *.*js",
38
+ "clean": "rimraf cjs esm out types",
39
+ "lint": "eslint src .*.*js *.*js",
42
40
  "postversion": "npm install @css-hooks/core@^$npm_package_version --force",
43
41
  "prepublishOnly": "tsc -p tsconfig.dist.json --outDir cjs --module commonjs && tsc -p tsconfig.dist.json --outDir esm --module es6 && tsc -p tsconfig.dist.json --declaration --emitDeclarationOnly --outDir types",
44
- "test": "jest"
42
+ "test": "tsc && node --test",
43
+ "test.watch": "tsc-watch --onSuccess 'node --test'"
45
44
  },
46
- "types": "types"
45
+ "types": "types",
46
+ "exports": {
47
+ ".": {
48
+ "import": "./esm/index.js",
49
+ "require": "./cjs/index.js",
50
+ "types": "./types/index.d.ts"
51
+ }
52
+ }
47
53
  }
package/types/index.d.ts CHANGED
@@ -47,5 +47,5 @@ export declare const createHooks: <HookProperties extends string>(config: Record
47
47
  */
48
48
  }) & {
49
49
  fallback?: "unset" | "revert-layer";
50
- }) | undefined) => readonly [`*{${string}}undefined` | `*{${string}}${string}`, (properties: import("@css-hooks/core").WithHooks<HookProperties, CSSProperties>) => CSSProperties];
50
+ }) | undefined) => [string, (properties: import("@css-hooks/core").WithHooks<HookProperties, CSSProperties>) => CSSProperties];
51
51
  export { recommended };