forked from acrazing/typescript-loadable-components-plugin
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpackage.json
More file actions
156 lines (156 loc) · 4.4 KB
/
package.json
File metadata and controls
156 lines (156 loc) · 4.4 KB
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
{
"name": "maxxton-typescript-loadable-components-plugin",
"version": "2.0.0",
"description": "A custom transformer of typescript that is used to add some necessary properties to loadable-components.",
"author": "acrazing <joking.young@gmail.com>",
"main": "lib/index.js",
"module": "lib/index.mjs",
"types": "lib/index.d.ts",
"keywords": [
"typescript",
"loadable-components",
"@loadable/components",
"plugin",
"transform",
"ttypescript",
"webpack",
"ts-loader"
],
"files": [
"assets/",
"lib/",
"src/"
],
"sideEffects": [
"*.css",
"*.less",
"*.scss"
],
"scripts": {
"build": "run-s clean && run-p build:cjs build:esm && run-s build:esm:rename build:cjs:rename",
"build-on-windows": "powershell -ExecutionPolicy Bypass -File build-on-windows.ps1",
"build:cjs": "tsc --outDir cjs --module commonjs --target es2015 --skipLibCheck",
"build:cjs:rename": "run-p build:cjs:rename:js build:cjs:rename:map",
"build:cjs:rename:js": "find ./cjs -type f -name '*.js' | sed -E 's/^\\.\\/cjs\\/(.+)$/\\1/' | xargs -I % mv ./cjs/% ./lib/%",
"build:cjs:rename:map": "find ./cjs -type f -name '*.js.map' | sed -E 's/^\\.\\/cjs\\/(.+)$/\\1/' | xargs -I % mv ./cjs/% ./lib/%",
"build:esm": "tsc --outDir lib --module esnext --target es5 --declaration --skipLibCheck",
"build:esm:rename": "run-p build:esm:rename:js build:esm:rename:map",
"build:esm:rename:js": "find ./lib -type f -name '*.js' | sed -E 's/^(.+)\\.js$/\\1/' | xargs -I % mv %.js %.mjs",
"build:esm:rename:map": "find ./lib -type f -name '*.js.map' | sed -E 's/^(.+)\\.js\\.map$/\\1/' | xargs -I % mv %.js.map %.mjs.map",
"clean": "rm -rf cjs esm lib build temp .cache",
"start": "npm run clean && npm run build:esm -- --watch",
"test": "jest",
"compare:babel": "babel -o ./compare/output_babel.js ./compare/source.ts",
"compare:self": "ttsc -p tsconfig.self.json && mv compare/source.js compare/output_typescript.js && rm -rf compare/input/*.js",
"compare": "rm -rf ./compare/output_* && run-p compare:babel compare:self && prettier --write ./compare/output_*"
},
"repository": {
"type": "git",
"url": "git@github.com:acrazing/typescript-loadable-components-plugin.git"
},
"license": "MIT",
"devDependencies": {
"@babel/cli": "^7.13.10",
"@babel/core": "^7.13.13",
"@babel/preset-env": "^7.13.12",
"@babel/preset-react": "^7.13.13",
"@babel/preset-typescript": "^7.13.0",
"@loadable/babel-plugin": "^5.13.2",
"@loadable/component": "^5.14.1",
"@types/jest": "^29.5.14",
"@types/loadable__component": "^5.13.3",
"@types/node": "^14.14.37",
"@types/react": "^17.0.3",
"husky": "^5.2.0",
"jest": "^29.7.0",
"lint-staged": "^10.5.4",
"npm-run-all": "^4.1.5",
"prettier": "^2.2.1",
"react": "^17.0.2",
"ts-jest": "^29.4.4",
"ts-loader": "^8.0.18",
"ttypescript": "^1.5.12"
},
"dependencies": {
"tslib": "^2.1.0",
"typescript": "^5.9.3"
},
"cliVersion": "8.11.2",
"husky": {
"hooks": {
"pre-commit": "lint-staged"
}
},
"lint-staged": {
"*.{js,jsx,ts,tsx,json,css,less,scss,md}": [
"prettier --write"
]
},
"prettier": {
"printWidth": 80,
"tabWidth": 2,
"useTabs": false,
"semi": true,
"singleQuote": true,
"jsxSingleQuote": false,
"trailingComma": "all",
"bracketSpacing": true,
"jsxBracketSameLine": false,
"arrowParens": "always",
"endOfLine": "lf"
},
"jest": {
"moduleFileExtensions": [
"ts",
"tsx",
"js",
"jsx",
"json",
"node",
"mjs"
],
"cacheDirectory": ".cache/jest",
"collectCoverage": false,
"collectCoverageFrom": [
"<rootDir>/src/**/*.{ts,tsx}",
"!**/*.d.ts"
],
"coverageDirectory": "temp/coverage",
"globals": {
"__DEV__": true,
"ENV": {}
},
"testMatch": [
"<rootDir>/src/**/*.spec.{ts,tsx}"
],
"transform": {
"^.+\\.tsx?$": "ts-jest"
}
},
"babel": {
"presets": [
[
"@babel/preset-env",
{
"targets": {
"chrome": "70"
},
"modules": false
}
],
[
"@babel/preset-typescript",
{
"isTSX": true,
"allExtensions": true
}
],
[
"@babel/preset-react"
]
],
"plugins": [
"@loadable/babel-plugin"
]
}
}