Skip to content

Commit ddcbbaf

Browse files
committed
feat: 초기 설정
1 parent 4ca4d26 commit ddcbbaf

13 files changed

Lines changed: 8063 additions & 0 deletions

File tree

.babelrc.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
module.exports = {
2+
presets: ['@babel/preset-react', '@babel/preset-typescript'],
3+
plugins: ['babel-plugin-styled-components'],
4+
};

.eslintignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
node_modules
2+
lib

.eslintrc.js

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
module.exports = {
2+
root: true,
3+
extends: [
4+
'airbnb',
5+
'eslint:recommended',
6+
'plugin:react/recommended',
7+
'plugin:@typescript-eslint/eslint-recommended',
8+
'plugin:@typescript-eslint/recommended',
9+
],
10+
parser: '@typescript-eslint/parser',
11+
plugins: ['@typescript-eslint', 'react', 'react-hooks'],
12+
rules: {
13+
'arrow-body-style': 0,
14+
15+
'react/function-component-definition': 0,
16+
'react-hooks/rules-of-hooks': 'error',
17+
'react-hooks/exhaustive-deps': 'warn',
18+
'react/jsx-filename-extension': [
19+
2,
20+
{
21+
extensions: ['.js', '.jsx', '.ts', '.tsx'],
22+
},
23+
],
24+
25+
'@typescript-eslint/no-non-null-assertion': 'off',
26+
'@typescript-eslint/ban-ts-comment': 'off',
27+
'@typescript-eslint/no-explicit-any': 'off',
28+
29+
'import/no-extraneous-dependencies': 0,
30+
'import/extensions': 'off',
31+
'import/prefer-default-export': 'off',
32+
'import/order': [
33+
'error',
34+
{
35+
groups: ['external', 'sibling'],
36+
pathGroups: [
37+
{
38+
pattern: 'react',
39+
group: 'external',
40+
position: 'before',
41+
},
42+
],
43+
pathGroupsExcludedImportTypes: ['react'],
44+
alphabetize: {
45+
order: 'asc',
46+
caseInsensitive: true,
47+
},
48+
'newlines-between': 'always',
49+
},
50+
],
51+
},
52+
settings: {
53+
'import/parsers': {
54+
'@typescript-eslint/parser': ['.ts', '.tsx'],
55+
},
56+
'import/resolver': {
57+
node: {
58+
extensions: ['.js', '.ts', '.jsx', '.tsx', '.json'],
59+
},
60+
},
61+
'import/extensions': ['.js', '.ts', '.mjs', '.jsx', '.tsx'],
62+
},
63+
env: {
64+
browser: true,
65+
node: true,
66+
},
67+
globals: {
68+
JSX: true,
69+
},
70+
};

.github/workflows/publish.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: build
2+
on:
3+
release:
4+
types: [published]
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
9+
steps:
10+
- name: Checkout
11+
uses: actions/checkout@v3
12+
13+
- name: Setup Node
14+
uses: actions/setup-node@v3
15+
with:
16+
node-version: 16.x
17+
registry-url: https://npm.pkg.github.com/
18+
19+
- name: Install dependencies
20+
run: npm install
21+
22+
- name: Build
23+
run: npm run build
24+
25+
- name: Publish
26+
run: npm publish
27+
28+
env:
29+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
node_modules
2+
lib

.prettierrc.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
module.exports = {
2+
printWidth: 120,
3+
tabWidth: 2,
4+
singleQuote: true,
5+
trailingComma: 'all',
6+
semi: true,
7+
useTabs: false,
8+
endOfLine: 'auto',
9+
bracketSpacing: true,
10+
bracketLine: true,
11+
};

0 commit comments

Comments
 (0)