UNPKG

9.16 kBJSONView Raw
1{
2 "name": "preact",
3 "amdName": "preact",
4 "version": "10.6.4",
5 "private": false,
6 "description": "Fast 3kb React-compatible Virtual DOM library.",
7 "main": "dist/preact.js",
8 "module": "dist/preact.module.js",
9 "umd:main": "dist/preact.umd.js",
10 "unpkg": "dist/preact.min.js",
11 "source": "src/index.js",
12 "exports": {
13 ".": {
14 "browser": "./dist/preact.module.js",
15 "umd": "./dist/preact.umd.js",
16 "import": "./dist/preact.mjs",
17 "require": "./dist/preact.js"
18 },
19 "./compat": {
20 "browser": "./compat/dist/compat.module.js",
21 "umd": "./compat/dist/compat.umd.js",
22 "require": "./compat/dist/compat.js",
23 "import": "./compat/dist/compat.mjs"
24 },
25 "./debug": {
26 "browser": "./debug/dist/debug.module.js",
27 "umd": "./debug/dist/debug.umd.js",
28 "require": "./debug/dist/debug.js",
29 "import": "./debug/dist/debug.mjs"
30 },
31 "./devtools": {
32 "browser": "./devtools/dist/devtools.module.js",
33 "umd": "./devtools/dist/devtools.umd.js",
34 "require": "./devtools/dist/devtools.js",
35 "import": "./devtools/dist/devtools.mjs"
36 },
37 "./hooks": {
38 "browser": "./hooks/dist/hooks.module.js",
39 "umd": "./hooks/dist/hooks.umd.js",
40 "require": "./hooks/dist/hooks.js",
41 "import": "./hooks/dist/hooks.mjs"
42 },
43 "./test-utils": {
44 "browser": "./test-utils/dist/testUtils.module.js",
45 "umd": "./test-utils/dist/testUtils.umd.js",
46 "require": "./test-utils/dist/testUtils.js",
47 "import": "./test-utils/dist/testUtils.mjs"
48 },
49 "./jsx-runtime": {
50 "browser": "./jsx-runtime/dist/jsxRuntime.module.js",
51 "umd": "./jsx-runtime/dist/jsxRuntime.umd.js",
52 "require": "./jsx-runtime/dist/jsxRuntime.js",
53 "import": "./jsx-runtime/dist/jsxRuntime.mjs"
54 },
55 "./jsx-dev-runtime": {
56 "browser": "./jsx-runtime/dist/jsxRuntime.module.js",
57 "umd": "./jsx-runtime/dist/jsxRuntime.umd.js",
58 "require": "./jsx-runtime/dist/jsxRuntime.js",
59 "import": "./jsx-runtime/dist/jsxRuntime.mjs"
60 },
61 "./compat/server": {
62 "require": "./compat/server.js",
63 "import": "./compat/server.mjs"
64 },
65 "./compat/jsx-runtime": {
66 "require": "./compat/jsx-runtime.js",
67 "import": "./compat/jsx-runtime.mjs"
68 },
69 "./compat/jsx-dev-runtime": {
70 "require": "./compat/jsx-dev-runtime.js",
71 "import": "./compat/jsx-dev-runtime.mjs"
72 },
73 "./compat/scheduler": {
74 "require": "./compat/scheduler.js",
75 "import": "./compat/scheduler.mjs"
76 },
77 "./package.json": "./package.json",
78 "./compat/package.json": "./compat/package.json",
79 "./debug/package.json": "./debug/package.json",
80 "./devtools/package.json": "./devtools/package.json",
81 "./hooks/package.json": "./hooks/package.json",
82 "./test-utils/package.json": "./test-utils/package.json",
83 "./jsx-runtime/package.json": "./jsx-runtime/package.json"
84 },
85 "license": "MIT",
86 "funding": {
87 "type": "opencollective",
88 "url": "https://opencollective.com/preact"
89 },
90 "types": "src/index.d.ts",
91 "scripts": {
92 "prepare": "run-s build && check-export-map",
93 "build": "npm-run-all --parallel build:*",
94 "build:core": "microbundle build --raw",
95 "build:core-min": "microbundle build --raw -f iife src/cjs.js -o dist/preact.min.js",
96 "build:debug": "microbundle build --raw --cwd debug",
97 "build:devtools": "microbundle build --raw --cwd devtools",
98 "build:hooks": "microbundle build --raw --cwd hooks",
99 "build:test-utils": "microbundle build --raw --cwd test-utils",
100 "build:compat": "microbundle build src/index.js src/scheduler.js --raw --cwd compat --globals 'preact/hooks=preactHooks'",
101 "build:jsx": "microbundle build --raw --cwd jsx-runtime",
102 "postbuild": "node ./config/node-13-exports.js && node ./config/compat-entries.js",
103 "dev": "microbundle watch --raw --format cjs",
104 "dev:hooks": "microbundle watch --raw --format cjs --cwd hooks",
105 "dev:compat": "microbundle watch --raw --format cjs --cwd compat --globals 'preact/hooks=preactHooks'",
106 "test": "npm-run-all build lint test:unit",
107 "test:unit": "run-p test:mocha test:karma:minify test:ts",
108 "test:ts": "run-p test:ts:*",
109 "test:ts:core": "tsc -p test/ts/ && mocha --require \"@babel/register\" test/ts/**/*-test.js",
110 "test:ts:compat": "tsc -p compat/test/ts/",
111 "test:mocha": "mocha --recursive --require \"@babel/register\" test/shared test/node",
112 "test:mocha:watch": "npm run test:mocha -- --watch",
113 "test:karma": "cross-env COVERAGE=true BABEL_NO_MODULES=true karma start karma.conf.js --single-run",
114 "test:karma:minify": "cross-env COVERAGE=true MINIFY=true BABEL_NO_MODULES=true karma start karma.conf.js --single-run",
115 "test:karma:watch": "cross-env BABEL_NO_MODULES=true karma start karma.conf.js --no-single-run",
116 "test:karma:hooks": "cross-env COVERAGE=false BABEL_NO_MODULES=true karma start karma.conf.js --grep=hooks/test/browser/**.js --no-single-run",
117 "test:karma:test-utils": "cross-env PERFORMANCE=false COVERAGE=false BABEL_NO_MODULES=true karma start karma.conf.js --grep=test-utils/test/shared/**.js --no-single-run",
118 "test:karma:bench": "cross-env PERFORMANCE=true COVERAGE=false BABEL_NO_MODULES=true karma start karma.conf.js --grep=test/benchmarks/**.js --single-run",
119 "benchmark": "npm run test:karma:bench -- no-single-run",
120 "lint": "eslint src test debug compat hooks test-utils"
121 },
122 "eslintConfig": {
123 "extends": [
124 "developit",
125 "prettier"
126 ],
127 "settings": {
128 "react": {
129 "pragma": "createElement"
130 }
131 },
132 "rules": {
133 "camelcase": [
134 1,
135 {
136 "allow": [
137 "__test__*",
138 "unstable_*",
139 "UNSAFE_*"
140 ]
141 }
142 ],
143 "no-unused-vars": [
144 2,
145 {
146 "args": "none",
147 "varsIgnorePattern": "^h|React$"
148 }
149 ],
150 "prefer-rest-params": 0,
151 "prefer-spread": 0,
152 "no-cond-assign": 0,
153 "react/jsx-no-bind": 0,
154 "react/no-danger": "off",
155 "react/prefer-stateless-function": 0,
156 "react/sort-comp": 0,
157 "jest/valid-expect": 0,
158 "jest/no-disabled-tests": 0,
159 "jest/no-test-callback": 0,
160 "jest/expect-expect": 0,
161 "jest/no-standalone-expect": 0,
162 "jest/no-export": 0,
163 "react/no-find-dom-node": 0
164 }
165 },
166 "eslintIgnore": [
167 "test/fixtures",
168 "test/ts/",
169 "*.ts",
170 "dist"
171 ],
172 "prettier": {
173 "singleQuote": true,
174 "trailingComma": "none",
175 "useTabs": true,
176 "tabWidth": 2
177 },
178 "lint-staged": {
179 "**/*.{js,jsx,ts,tsx,yml}": [
180 "prettier --write"
181 ]
182 },
183 "husky": {
184 "hooks": {
185 "pre-commit": "lint-staged"
186 }
187 },
188 "files": [
189 "src",
190 "dist",
191 "compat/dist",
192 "compat/src",
193 "compat/server.js",
194 "compat/server.mjs",
195 "compat/scheduler.js",
196 "compat/scheduler.mjs",
197 "compat/test-utils.js",
198 "compat/jsx-runtime.js",
199 "compat/jsx-runtime.mjs",
200 "compat/jsx-dev-runtime.js",
201 "compat/jsx-dev-runtime.mjs",
202 "compat/package.json",
203 "debug/dist",
204 "debug/src",
205 "debug/package.json",
206 "devtools/dist",
207 "devtools/src",
208 "devtools/package.json",
209 "hooks/dist",
210 "hooks/src",
211 "hooks/package.json",
212 "jsx-runtime/dist",
213 "jsx-runtime/src",
214 "jsx-runtime/package.json",
215 "test-utils/src",
216 "test-utils/package.json",
217 "test-utils/dist"
218 ],
219 "keywords": [
220 "preact",
221 "react",
222 "ui",
223 "user interface",
224 "virtual dom",
225 "vdom",
226 "components",
227 "dom diff",
228 "front-end",
229 "framework"
230 ],
231 "authors": [
232 "The Preact Authors (https://github.com/preactjs/preact/contributors)"
233 ],
234 "repository": "preactjs/preact",
235 "bugs": "https://github.com/preactjs/preact/issues",
236 "homepage": "https://preactjs.com",
237 "devDependencies": {
238 "@babel/core": "^7.7.0",
239 "@babel/plugin-proposal-object-rest-spread": "^7.6.2",
240 "@babel/plugin-transform-react-jsx": "^7.7.0",
241 "@babel/plugin-transform-react-jsx-source": "^7.7.4",
242 "@babel/preset-env": "^7.7.1",
243 "@babel/register": "^7.7.0",
244 "@types/chai": "^4.1.2",
245 "@types/mocha": "^5.0.0",
246 "@types/node": "^14.14.10",
247 "babel-plugin-istanbul": "^6.0.0",
248 "babel-plugin-transform-async-to-promises": "^0.8.15",
249 "babel-plugin-transform-rename-properties": "0.1.0",
250 "benchmark": "^2.1.4",
251 "chai": "^4.1.2",
252 "check-export-map": "^1.2.0",
253 "coveralls": "^3.0.0",
254 "cross-env": "^7.0.2",
255 "csstype": "^3.0.5",
256 "diff": "^5.0.0",
257 "errorstacks": "^2.3.0",
258 "esbuild": "^0.12.24",
259 "eslint": "5.15.1",
260 "eslint-config-developit": "^1.1.1",
261 "eslint-config-prettier": "^6.5.0",
262 "eslint-plugin-react": "7.12.4",
263 "husky": "^4.3.0",
264 "karma": "^6.3.4",
265 "karma-chai-sinon": "^0.1.5",
266 "karma-chrome-launcher": "^3.1.0",
267 "karma-coverage": "^2.0.3",
268 "karma-esbuild": "^2.2.0",
269 "karma-mocha": "^2.0.1",
270 "karma-mocha-reporter": "^2.2.5",
271 "karma-sauce-launcher": "^4.3.4",
272 "karma-sinon": "^1.0.5",
273 "karma-sourcemap-loader": "^0.3.7",
274 "kolorist": "^1.2.10",
275 "lint-staged": "^10.5.2",
276 "lodash": "^4.17.20",
277 "microbundle": "^0.11.0",
278 "mocha": "^8.2.1",
279 "npm-merge-driver-install": "^1.1.1",
280 "npm-run-all": "^4.0.0",
281 "prettier": "^1.18.2",
282 "prop-types": "^15.7.2",
283 "sinon": "^9.2.3",
284 "sinon-chai": "^3.5.0",
285 "typescript": "4.4.2"
286 }
287}