@blocklet/pages-kit-core 0.5.30 → 0.5.32

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": "@blocklet/pages-kit-core",
3
- "version": "0.5.30",
3
+ "version": "0.5.32",
4
4
  "description": "Pages Kit core",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -10,16 +10,22 @@
10
10
  "license": "ISC",
11
11
  "main": "./lib/cjs/index.js",
12
12
  "module": "./lib/esm/index.js",
13
- "types": "./lib/types/index.d.js",
13
+ "types": "./lib/types/index.d.ts",
14
14
  "exports": {
15
15
  ".": {
16
16
  "import": "./lib/esm/index.js",
17
- "require": "./lib/cjs/index.js"
17
+ "require": "./lib/cjs/index.js",
18
+ "types": "./lib/types/index.d.ts"
19
+ },
20
+ "./*": {
21
+ "import": "./lib/esm/*",
22
+ "require": "./lib/cjs/*",
23
+ "types": "./lib/types/*"
18
24
  }
19
25
  },
20
26
  "typesVersions": {
21
27
  "*": {
22
- "*": [
28
+ ".": [
23
29
  "./lib/types/index.d.ts"
24
30
  ]
25
31
  }
@@ -39,31 +45,43 @@
39
45
  "axios": "^1.7.4",
40
46
  "lodash": "^4.17.21",
41
47
  "nanoid": "^3.3.7",
42
- "typescript": "~5.5.4"
48
+ "typescript": "~5.5.4",
49
+ "yaml": "^2.5.0"
43
50
  },
44
51
  "peerDependencies": {
45
52
  "axios": "^1.7.4",
46
53
  "react": "^18.2.0",
47
54
  "react-dom": "^18.2.0",
48
- "react-router-dom": "^6.16.0"
55
+ "react-router-dom": "^6.16.0",
56
+ "yaml": "^2.5.0"
49
57
  },
50
58
  "devDependencies": {
59
+ "@types/chai": "^4.3.11",
51
60
  "@types/lodash": "^4.17.7",
61
+ "@types/mocha": "^10.0.6",
52
62
  "@types/react": "^18.3.4",
53
63
  "@types/react-helmet": "^6.1.11",
54
64
  "@types/react-scroll-to-bottom": "^4.2.5",
55
65
  "@types/react-syntax-highlighter": "^15.5.13",
66
+ "@types/sinon": "^17.0.3",
56
67
  "axios": "^1.7.4",
68
+ "c8": "^9.1.0",
69
+ "chai": "^5.2.0",
70
+ "mocha": "^11.2.2",
57
71
  "npm-run-all": "^4.1.5",
58
72
  "react": "^18.3.1",
59
73
  "react-dom": "^18.3.1",
60
74
  "react-router-dom": "^6.26.1",
61
- "rimraf": "^6.0.1"
75
+ "rimraf": "^6.0.1",
76
+ "sinon": "^20.0.0",
77
+ "ts-node": "^10.9.2"
62
78
  },
63
79
  "scripts": {
64
80
  "lint": "eslint src --ext .mjs,.js,.jsx,.ts,.tsx",
65
81
  "lint:fix": "npm run lint -- --fix",
66
- "build": "run-p build:*",
82
+ "test": "mocha --require ts-node/register tests/**/*.ts",
83
+ "test:coverage": "c8 --check-coverage --reporter=html --reporter=text-summary npm test",
84
+ "build": "rimraf lib && run-p build:*",
67
85
  "build:cjs": "tsc --module commonjs --outDir lib/cjs",
68
86
  "build:esm": "tsc --module es2022 --outDir lib/esm",
69
87
  "build:types": "tsc --declaration --emitDeclarationOnly --outDir lib/types",
package/tsconfig.json CHANGED
@@ -12,5 +12,10 @@
12
12
  // "@blocklet/ai-runtime/*": ["../../../ai-studio/packages/ai-runtime/src/*"]
13
13
  // "@blocklet/ai-kit/*": ["../../../ai-kit/packages/ai-kit/src/*"]
14
14
  }
15
- }
15
+ },
16
+ "rules": {
17
+ "max-classes-per-file": "off"
18
+ },
19
+ "exclude": ["node_modules", "lib"],
20
+ "include": ["src", "test"]
16
21
  }