Skip to content

Commit cef9ae8

Browse files
committed
Initial commit
0 parents  commit cef9ae8

12 files changed

+216
-0
lines changed

.editorconfig

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# http://editorconfig.org
2+
root = true
3+
4+
[*]
5+
indent_style = space
6+
indent_size = 2
7+
end_of_line = lf
8+
charset = utf-8
9+
trim_trailing_whitespace = true
10+
insert_final_newline = true
11+
12+
[*.md]
13+
trim_trailing_whitespace = false
14+
15+
[Makefile]
16+
indent_style = tab

.eslintrc.js

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
const base = require('@umijs/fabric/dist/eslint');
2+
3+
module.exports = {
4+
...base,
5+
rules: {
6+
...base.rules,
7+
},
8+
};

.fatherrc.ts

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
// https://github.com/umijs/father
2+
3+
export default {
4+
esm: {
5+
type: 'rollup',
6+
importLibToEs: true,
7+
},
8+
cjs: 'rollup',
9+
runtimeHelpers: true,
10+
};

.gitignore

+54
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# @source: https://github.com/xrkffgg/gitignore/blob/master/.gitignore
2+
3+
# production
4+
/dist
5+
/docs-dist
6+
7+
# Log file
8+
*.log
9+
npm-debug.log*
10+
yarn-debug.log*
11+
yarn-error.log*
12+
13+
# Private
14+
assets/index.css
15+
16+
# misc
17+
.DS_Store
18+
19+
# dependencies
20+
node_modules
21+
yarn.lock
22+
package-lock.json
23+
24+
# local env files
25+
.env.local
26+
.env.*.local
27+
28+
# Compiled file
29+
*.class
30+
*.css.map
31+
*.sass.map
32+
*.scss.map
33+
34+
# Editor directories and files
35+
.idea
36+
.vscode
37+
*.suo
38+
*.ntvs*
39+
*.njsproj
40+
*.sln
41+
*.sw?
42+
~$*.*
43+
44+
# umi
45+
.umi
46+
.umi-production
47+
.umi-test
48+
.env.local
49+
50+
# cache
51+
.sass-cache/
52+
53+
# test
54+
coverage

.prettierignore

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
**/*.svg
2+
**/*.ejs
3+
**/*.html
4+
package.json
5+
.umi
6+
.umi-production
7+
.umi-test
8+
.dist

.prettierrc

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"singleQuote": true,
3+
"trailingComma": "all",
4+
"printWidth": 80,
5+
"overrides": [
6+
{
7+
"files": ".prettierrc",
8+
"options": { "parser": "json" }
9+
}
10+
]
11+
}

CHANGELOG.md

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# 🗓 Changelog
2+
3+
## 1.0.0
4+
5+
`2021.xx.xx`
6+
7+
🎉 Init

LICENSE

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2021-present xrkffgg
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Ts Template
2+
3+
xxxx
4+
5+
## Changelog
6+
7+
[CHANGELOG](./CHANGELOG.md)
8+
9+
## LICENSE
10+
11+
[MIT](.LICENSE)

package.json

+42
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
{
2+
"private": false,
3+
"name": "xx",
4+
"version": "0.0.1",
5+
"scripts": {
6+
"build": "father-build",
7+
"format": "prettier --write \"**/*.{js,jsx,tsx,ts,less,md,json}\"",
8+
"prepublishOnly": "npm run build && np --yolo --no-publish",
9+
"lint": "eslint src/ --ext .tsx,.ts",
10+
"all": "npm run build && npm run lint"
11+
},
12+
"main": "dist/index.js",
13+
"module": "dist/index.esm.js",
14+
"typings": "dist/index.d.ts",
15+
"repository": {
16+
"type": "git",
17+
"url": "https://github.com/ant-js/ts",
18+
"branch": "main"
19+
},
20+
"author": "xrkffgg",
21+
"homepage": "https://github.com/ant-js/ts",
22+
"keywords": [
23+
"ts"
24+
],
25+
"files": [
26+
"dist",
27+
"README.md",
28+
"CHANGELOG.md"
29+
],
30+
"license": "MIT",
31+
"dependencies": {
32+
"@babel/runtime": "^7.12.5"
33+
},
34+
"devDependencies": {
35+
"@umijs/fabric": "^2.2.2",
36+
"eslint": "^7.15.0",
37+
"father-build": "^1.17.2",
38+
"np": "^7.0.0",
39+
"prettier": "^2.2.1",
40+
"typescript": "^4.1.2"
41+
}
42+
}

src/index.ts

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
const A: string = 'A';
2+
3+
export default A;

tsconfig.json

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
{
2+
"compilerOptions": {
3+
"target": "esnext",
4+
"module": "esnext",
5+
"moduleResolution": "node",
6+
"importHelpers": true,
7+
"jsx": "react",
8+
"esModuleInterop": true,
9+
"sourceMap": true,
10+
"baseUrl": "./",
11+
"strict": true,
12+
"allowSyntheticDefaultImports": true
13+
},
14+
"exclude": [
15+
"node_modules",
16+
"lib",
17+
"es",
18+
"dist",
19+
"typings",
20+
"**/__test__",
21+
"test",
22+
"docs",
23+
"tests"
24+
]
25+
}

0 commit comments

Comments
 (0)