Skip to content

Commit

Permalink
feat(app): update project structure
Browse files Browse the repository at this point in the history
Add prettier and eslint

BREAKING CHANGE: Update proejct
  • Loading branch information
imgarylai committed Nov 24, 2020
1 parent b0b15f2 commit 2c11276
Show file tree
Hide file tree
Showing 9 changed files with 2,968 additions and 1,784 deletions.
25 changes: 25 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
module.exports = {
env: {
browser: true,
es2021: true,
node: true,
},
extends: ['plugin:react/recommended'],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaFeatures: {
jsx: true,
},
ecmaVersion: 12,
sourceType: 'module',
},
plugins: ['react', '@typescript-eslint'],
rules: {},
settings: {
'import/resolver': {
node: {
extensions: ['.js', '.jsx', '.ts', '.tsx'],
},
},
},
};
6 changes: 6 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"semi": true,
"trailingComma": "all",
"printWidth": 100,
"singleQuote": true
}
3,191 changes: 2,166 additions & 1,025 deletions package-lock.json

Large diffs are not rendered by default.

15 changes: 12 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
"scripts": {
"build": "microbundle",
"dev": "microbundle watch",
"lint": "eslint --ext .ts,.tsx ./src",
"commit": "git-cz",
"semantic-release": "semantic-release"
},
Expand All @@ -27,12 +28,20 @@
"react": ">= 16.8.0"
},
"devDependencies": {
"@commitlint/cli": "8.3.5",
"@commitlint/config-conventional": "8.3.4",
"@commitlint/prompt": "8.3.5",
"@commitlint/cli": "11.0.0",
"@commitlint/config-conventional": "11.0.0",
"@commitlint/prompt": "11.0.0",
"@types/react": "16.14.2",
"@typescript-eslint/eslint-plugin": "4.8.2",
"@typescript-eslint/parser": "4.8.2",
"commitizen": "4.2.2",
"cz-conventional-changelog": "3.3.0",
"eslint": "7.14.0",
"eslint-config-prettier": "6.15.0",
"eslint-plugin-import": "2.22.1",
"eslint-plugin-jsx-a11y": "6.4.1",
"eslint-plugin-react": "7.21.5",
"eslint-plugin-react-hooks": "4.2.0",
"husky": "4.3.0",
"microbundle": "0.12.4",
"prettier": "2.0.5",
Expand Down
48 changes: 25 additions & 23 deletions src/data/cities.ts
Original file line number Diff line number Diff line change
@@ -1,24 +1,26 @@
export const cities = [
"台北市",
"基隆市",
"新北市",
"桃園市",
"新竹市",
"新竹縣",
"苗栗縣",
"台中市",
"彰化縣",
"南投縣",
"雲林縣",
"嘉義市",
"嘉義縣",
"台南市",
"高雄市",
"屏東縣",
"台東縣",
"花蓮縣",
"宜蘭縣",
"澎湖縣",
"金門縣",
"連江縣",
const cities = [
'台北市',
'基隆市',
'新北市',
'桃園市',
'新竹市',
'新竹縣',
'苗栗縣',
'台中市',
'彰化縣',
'南投縣',
'雲林縣',
'嘉義市',
'嘉義縣',
'台南市',
'高雄市',
'屏東縣',
'台東縣',
'花蓮縣',
'宜蘭縣',
'澎湖縣',
'金門縣',
'連江縣',
];

export default cities;
Loading

0 comments on commit 2c11276

Please sign in to comment.