-
Notifications
You must be signed in to change notification settings - Fork 171
/
package.json
124 lines (124 loc) · 4.5 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
{
"name": "htm",
"version": "3.1.1",
"description": "The Tagged Template syntax for Virtual DOM. Only browser-compatible syntax.",
"main": "dist/htm.js",
"umd:main": "dist/htm.umd.js",
"module": "dist/htm.module.js",
"types": "dist/htm.d.ts",
"exports": {
".": {
"types": "./dist/htm.d.ts",
"browser": "./dist/htm.module.js",
"umd": "./dist/htm.umd.js",
"import": "./dist/htm.mjs",
"require": "./dist/htm.js"
},
"./": "./",
"./preact": {
"types": "./preact/index.d.ts",
"browser": "./preact/index.module.js",
"umd": "./preact/index.umd.js",
"import": "./preact/index.mjs",
"require": "./preact/index.js"
},
"./preact/standalone": {
"types": "./preact/index.d.ts",
"browser": "./preact/standalone.module.js",
"umd": "./preact/standalone.umd.js",
"import": "./preact/standalone.mjs",
"require": "./preact/standalone.js"
},
"./react": {
"types": "./react/index.d.ts",
"browser": "./react/index.module.js",
"umd": "./react/index.umd.js",
"import": "./react/index.mjs",
"require": "./react/index.js"
},
"./mini": {
"types": "./mini/index.d.ts",
"browser": "./mini/index.module.js",
"umd": "./mini/index.umd.js",
"import": "./mini/index.mjs",
"require": "./mini/index.js"
}
},
"scripts": {
"build": "npm run -s build:main && npm run -s build:mini && npm run -s build:preact && npm run -s build:react && npm run -s build:babel && npm run -s build:babel-transform-jsx && npm run -s build:mjsalias",
"build:main": "microbundle src/index.mjs -f es,umd --no-sourcemap --target web && microbundle src/cjs.mjs -f iife --no-sourcemap --target web && cp src/index.d.ts dist/htm.d.ts",
"build:mini": "microbundle src/index.mjs -o ./mini/index.js -f es,umd --no-sourcemap --target web --alias ./constants.mjs=./constants-mini.mjs && microbundle src/cjs.mjs -o ./mini/index.js -f iife --no-sourcemap --target web --alias ./constants.mjs=./constants-mini.mjs && cp src/index.d.ts mini",
"build:preact": "cd src/integrations/preact && npm run build",
"build:react": "cd src/integrations/react && npm run build",
"build:babel": "cd packages/babel-plugin-htm && npm run build",
"build:babel-transform-jsx": "cd packages/babel-plugin-transform-jsx-to-htm && npm run build",
"build:mjsalias": "cp dist/htm.module.js dist/htm.mjs && cp mini/index.module.js mini/index.mjs && cp preact/index.module.js preact/index.mjs && cp preact/standalone.module.js preact/standalone.mjs && cp react/index.module.js react/index.mjs",
"test": "eslint src/**/*.mjs test/**/*.mjs --ignore-path .gitignore && npm run build && jest test",
"test:perf": "v8 test/__perftest.mjs",
"test:dist": "npm pack && mv htm*.tgz test/fixtures/esm/htm.tgz && cd test/fixtures/esm && npm install && node index.js",
"release": "npm t && git commit -am \"$npm_package_version\" && git tag $npm_package_version && git push && git push --tags && npm publish"
},
"files": [
"dist",
"mini",
"preact",
"react",
"src"
],
"eslintConfig": {
"extends": "developit",
"rules": {
"prefer-const": 0,
"prefer-spread": 0,
"prefer-rest-params": 0,
"func-style": 0
}
},
"jest": {
"testURL": "http://localhost",
"testMatch": [
"**/__tests__/**/*.?(m)js?(x)",
"**/?(*.)(spec|test).?(m)js?(x)"
],
"transform": {
"\\.m?js$": "babel-jest"
},
"moduleFileExtensions": [
"mjs",
"js"
],
"moduleNameMapper": {
"^babel-plugin-transform-jsx-to-htm$": "<rootDir>/packages/babel-plugin-transform-jsx-to-htm/index.mjs",
"^babel-plugin-htm$": "<rootDir>/packages/babel-plugin-htm/index.mjs",
"^htm$": "<rootDir>/src/index.mjs",
"^htm/preact$": "<rootDir>/src/integrations/preact/index.mjs"
}
},
"repository": "developit/htm",
"keywords": [
"Hyperscript Tagged Markup",
"tagged template",
"template literals",
"html",
"htm",
"jsx",
"virtual dom",
"hyperscript"
],
"author": "Jason Miller <[email protected]>",
"license": "Apache-2.0",
"homepage": "https://github.com/developit/htm",
"devDependencies": {
"@babel/core": "^7.2.2",
"@babel/preset-env": "^7.1.6",
"@types/jest": "^26.0.24",
"babel-jest": "^24.1.0",
"babel-preset-env": "^1.7.0",
"eslint": "^5.2.0",
"eslint-config-developit": "^1.1.1",
"jest": "^24.1.0",
"microbundle": "^0.10.1",
"preact": "^10.2.0",
"react": "^16.8.3"
}
}