Skip to content

Commit

Permalink
refactor: structure
Browse files Browse the repository at this point in the history
  • Loading branch information
tmm committed Dec 21, 2021
1 parent c0638e0 commit b311af0
Show file tree
Hide file tree
Showing 89 changed files with 6,429 additions and 7,700 deletions.
1 change: 0 additions & 1 deletion .env.sample

This file was deleted.

2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
dist
24 changes: 2 additions & 22 deletions .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,14 @@
},
"allowImportExportEverywhere": true
},
"plugins": ["@typescript-eslint", "import", "react", "jest"],
"plugins": ["@typescript-eslint", "import", "jest"],
"extends": [
"eslint:recommended",
"plugin:eslint-comments/recommended",
"plugin:@typescript-eslint/recommended",
"plugin:import/errors",
"plugin:import/warnings",
"plugin:import/typescript",
"plugin:react/recommended",
"plugin:react-hooks/recommended",
"plugin:prettier/recommended",
"prettier"
Expand Down Expand Up @@ -51,26 +50,7 @@
"ignoreDeclarationSort": true,
"ignoreMemberSort": false
}
],
// `eslint-plugin-react`
// https://github.com/yannickcr/eslint-plugin-react
"react/display-name": "off",
"react/jsx-boolean-value": ["warn", "never"],
"react/jsx-curly-brace-presence": [
"error",
{ "props": "never", "children": "ignore" }
],
"react/jsx-sort-props": [
"error",
{
"callbacksLast": true
}
],
"react/jsx-wrap-multilines": "error",
"react/no-array-index-key": "error",
"react/no-multi-comp": "off",
"react/prop-types": "off",
"react/self-closing-comp": "warn"
]
},
"settings": {
"import/parsers": {
Expand Down
44 changes: 34 additions & 10 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,51 @@
name: Main

on:
pull_request:
push:
branches: [main]
on: [push, pull_request]

jobs:
build:
name: Build
needs: lint
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14]
pnpm-version: [6.24.2]
steps:
- uses: actions/checkout@v2
- uses: pnpm/action-setup@v2.0.1
with:
version: ${{ matrix.pnpm-version }}
- name: Set up Node ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
cache: 'pnpm'
node-version: ${{ matrix.node-version }}
- name: Install Dependencies
run: pnpm i
- name: Build
run: pnpm build

lint:
name: Lint
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14]
pnpm-version: [6.24.2]
steps:
- uses: actions/checkout@v2
- uses: pnpm/action-setup@v2.0.1
with:
version: ${{ matrix.pnpm-version }}
- name: Set up Node ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
cache: 'yarn'
cache: 'pnpm'
node-version: ${{ matrix.node-version }}
- name: Install dependencies
run: yarn install
- name: Lint
run: yarn lint
- name: Install Dependencies
run: pnpm i
- name: Lint code
run: pnpm lint
- name: Check types
run: yarn lint:types
run: pnpm lint:types
19 changes: 6 additions & 13 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,22 +1,15 @@
node_modules
*.local
.DS_Store
.eslintcache
.next
dist
dist-ssr
*.local
npm-debug.log*
yarn-debug.log*
yarn-error.log*
node_modules
.pnpm-debug.log*
tsconfig.tsbuildinfo

# local env files
.env
.env.local
.env.development.local
.env.test.local
.env.production.local

.yarn/*
!.yarn/patches
!.yarn/releases
!.yarn/plugins
!.yarn/sdks
!.yarn/versions
2 changes: 1 addition & 1 deletion .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

yarn lint-staged
pnpm lint-staged
1 change: 1 addition & 0 deletions .node-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
14.18.2
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
dist
1 change: 1 addition & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@
"tabWidth": 2,
"trailingComma": "all"
}

9 changes: 0 additions & 9 deletions .yarn/plugins/@yarnpkg/plugin-typescript.cjs

This file was deleted.

768 changes: 0 additions & 768 deletions .yarn/releases/yarn-berry.cjs

This file was deleted.

20 changes: 0 additions & 20 deletions .yarn/sdks/eslint/bin/eslint.js

This file was deleted.

20 changes: 0 additions & 20 deletions .yarn/sdks/eslint/lib/api.js

This file was deleted.

6 changes: 0 additions & 6 deletions .yarn/sdks/eslint/package.json

This file was deleted.

5 changes: 0 additions & 5 deletions .yarn/sdks/integrations.yml

This file was deleted.

20 changes: 0 additions & 20 deletions .yarn/sdks/prettier/index.js

This file was deleted.

6 changes: 0 additions & 6 deletions .yarn/sdks/prettier/package.json

This file was deleted.

20 changes: 0 additions & 20 deletions .yarn/sdks/typescript/bin/tsc

This file was deleted.

20 changes: 0 additions & 20 deletions .yarn/sdks/typescript/bin/tsserver

This file was deleted.

20 changes: 0 additions & 20 deletions .yarn/sdks/typescript/lib/tsc.js

This file was deleted.

Loading

0 comments on commit b311af0

Please sign in to comment.