-
-
Notifications
You must be signed in to change notification settings - Fork 621
/
package.json
191 lines (191 loc) · 6.73 KB
/
package.json
1
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
{
"name": "jotai",
"description": "👻 Primitive and flexible state management for React",
"private": true,
"type": "commonjs",
"version": "2.10.3",
"main": "./index.js",
"types": "./index.d.ts",
"typesVersions": {
">=4.8": {
"esm/*": [
"esm/*"
],
"*": [
"*"
]
},
">=3.8": {
"esm/*": [
"ts3.8/*"
],
"*": [
"ts3.8/*"
]
},
"*": {
"esm/*": [
"ts_version_3.8_and_above_is_required.d.ts"
],
"*": [
"ts_version_3.8_and_above_is_required.d.ts"
]
}
},
"exports": {
"./package.json": "./package.json",
".": {
"import": {
"types": "./esm/index.d.mts",
"default": "./esm/index.mjs"
},
"default": {
"types": "./index.d.ts",
"default": "./index.js"
}
},
"./*": {
"import": {
"types": "./esm/*.d.mts",
"default": "./esm/*.mjs"
},
"default": {
"types": "./*.d.ts",
"default": "./*.js"
}
}
},
"files": [
"**"
],
"sideEffects": false,
"scripts": {
"prebuild": "shx rm -rf dist",
"build": "pnpm run prebuild && pnpm run '/^build:.*/' && pnpm run postbuild",
"build-watch": "pnpm run '/^build:.*/' --watch",
"build:base": "rollup -c",
"build:utils": "rollup -c --config-utils",
"build:babel:plugin-debug-label": "rollup -c --config-babel_plugin-debug-label",
"build:babel:plugin-react-refresh": "rollup -c --config-babel_plugin-react-refresh",
"build:babel:preset": "rollup -c --config-babel_preset",
"build:vanilla": "rollup -c --config-vanilla",
"build:vanilla:utils": "rollup -c --config-vanilla_utils",
"build:react": "rollup -c --config-react --client-only",
"build:react:utils": "rollup -c --config-react_utils --client-only",
"postbuild": "pnpm patch-d-ts && pnpm copy && pnpm patch-ts3.8 && pnpm patch-old-ts && pnpm patch-esm-ts && pnpm patch-readme",
"prettier": "prettier '*.{js,json,md}' '{src,tests,benchmarks,docs}/**/*.{ts,tsx,md,mdx}' --write",
"eslint": "eslint --fix --no-eslintrc --c .eslintrc.json '*.{js,ts}' '{src,tests,benchmarks}/**/*.{ts,tsx}'",
"test": "pnpm run '/^test:.*/'",
"test:format": "prettier '*.{js,json,md}' '{src,tests,benchmarks,docs}/**/*.{ts,tsx,md,mdx}' --list-different",
"test:types": "tsc --noEmit",
"test:lint": "eslint --no-eslintrc --c .eslintrc.json '*.{js,ts}' '{src,tests,benchmarks}/**/*.{ts,tsx}'",
"test:spec": "vitest run",
"test-build:spec": "vitest run",
"patch-d-ts": "node -e \"var {entries}=require('./rollup.config.js');require('shelljs').find('dist/**/*.d.ts').forEach(f=>{entries.forEach(({find,replacement})=>require('shelljs').sed('-i',new RegExp(' from \\''+find.source.slice(0,-1)+'\\';$'),' from \\''+replacement+'\\';',f));require('shelljs').sed('-i',/ from '(\\.[^']+)\\.ts';$/,' from \\'\\$1\\';',f)})\"",
"copy": "shx cp -r dist/src/* dist/esm && shx cp -r dist/src/* dist && shx rm -rf dist/src && shx rm -rf dist/{src,tests} && downlevel-dts dist dist/ts3.8 --to=3.8 && shx cp package.json readme.md LICENSE dist && json -I -f dist/package.json -e \"this.private=false; this.devDependencies=undefined; this.optionalDependencies=undefined; this.scripts=undefined; this.prettier=undefined;\"",
"patch-ts3.8": "node -e \"require('shelljs').find('dist/ts3.8/**/*.d.ts').forEach(f=>require('fs').appendFileSync(f,'declare type Awaited<T> = T extends Promise<infer V> ? V : T;'))\"",
"patch-old-ts": "shx touch dist/ts_version_3.8_and_above_is_required.d.ts",
"patch-esm-ts": "node -e \"require('shelljs').find('dist/esm/**/*.d.ts').forEach(f=>{var f2=f.replace(/\\.ts$/,'.mts');require('fs').renameSync(f,f2);require('shelljs').sed('-i',/ from '(\\.[^']+)';$/,' from \\'\\$1.mjs\\';',f2);require('shelljs').sed('-i',/^declare module '(\\.[^']+)'/,'declare module \\'\\$1.mjs\\'',f2)})\"",
"patch-readme": "shx sed -i 's/.*Jotai \\(dark mode\\).*//' dist/readme.md"
},
"engines": {
"node": ">=12.20.0"
},
"prettier": {
"semi": false,
"singleQuote": true
},
"repository": {
"type": "git",
"url": "git+https://github.com/pmndrs/jotai.git"
},
"keywords": [
"react",
"state",
"manager",
"management",
"recoil",
"store"
],
"author": "Daishi Kato",
"contributors": [],
"license": "MIT",
"bugs": {
"url": "https://github.com/pmndrs/jotai/issues"
},
"homepage": "https://github.com/pmndrs/jotai",
"packageManager": "[email protected]",
"devDependencies": {
"@babel/core": "^7.26.0",
"@babel/plugin-transform-react-jsx": "^7.25.9",
"@babel/plugin-transform-typescript": "^7.25.9",
"@babel/preset-env": "^7.26.0",
"@babel/template": "^7.25.9",
"@rollup/plugin-alias": "^5.1.1",
"@rollup/plugin-babel": "^6.0.4",
"@rollup/plugin-node-resolve": "^15.3.0",
"@rollup/plugin-replace": "^6.0.1",
"@rollup/plugin-terser": "^0.4.4",
"@rollup/plugin-typescript": "^12.1.1",
"@testing-library/dom": "^10.4.0",
"@testing-library/jest-dom": "^6.6.3",
"@testing-library/react": "^16.0.1",
"@testing-library/user-event": "^14.5.2",
"@types/babel__core": "^7.20.5",
"@types/babel__template": "^7.4.4",
"@types/node": "^22.9.0",
"@types/react": "^18.3.12",
"@types/react-dom": "^18.3.1",
"@typescript-eslint/eslint-plugin": "^8.14.0",
"@typescript-eslint/parser": "^8.14.0",
"@vitest/coverage-v8": "^2.1.5",
"@vitest/eslint-plugin": "^1.1.10",
"@vitest/ui": "^2.1.5",
"benny": "^3.7.1",
"downlevel-dts": "^0.11.0",
"esbuild": "^0.24.0",
"eslint": "8.57.0",
"eslint-config-prettier": "^9.1.0",
"eslint-import-resolver-alias": "^1.1.2",
"eslint-plugin-import": "^2.31.0",
"eslint-plugin-jest-dom": "^5.5.0",
"eslint-plugin-prettier": "^5.2.1",
"eslint-plugin-react": "^7.37.2",
"eslint-plugin-react-compiler": "19.0.0-beta-a7bf2bd-20241110",
"eslint-plugin-react-hooks": "^5.0.0",
"eslint-plugin-testing-library": "^6.4.0",
"jest-leak-detector": "^29.7.0",
"jsdom": "^25.0.1",
"json": "^11.0.0",
"prettier": "^3.3.3",
"react": "19.0.0-rc.1",
"react-dom": "19.0.0-rc.1",
"rollup": "^4.27.2",
"rollup-plugin-banner2": "^1.3.0",
"rollup-plugin-esbuild": "^6.1.1",
"rxjs": "^7.8.1",
"shelljs": "^0.8.5",
"shx": "^0.3.4",
"ts-expect": "^1.3.0",
"typescript": "^5.6.3",
"vitest": "^2.1.5",
"wonka": "^6.3.4"
},
"peerDependencies": {
"@types/react": ">=17.0.0",
"react": ">=17.0.0"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
},
"react": {
"optional": true
}
},
"pnpm": {
"patchedDependencies": {
"@testing-library/[email protected]": "patches/@[email protected]"
}
}
}