diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..2066ff6 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,10 @@ +root = true + +[*] +insert_final_newline = true +charset = utf-8 + +[*.js] +indent_style = space +indent_size = 4 +trim_trailing_whitespace = true diff --git a/.eslintrc.json b/.eslintrc.json new file mode 100644 index 0000000..a0d8ed1 --- /dev/null +++ b/.eslintrc.json @@ -0,0 +1,28 @@ +{ + "extends": "react-app", + "parserOptions": { + "ecmaVersion": 6, + "sourceType": "module", + "ecmaFeatures": { + "jsx": true + } + }, + "rules": { + "semi": "error", + "indent": [ + "error", + 4, + { + "SwitchCase": 1 + } + ], + "quotes": ["warn", "double"], + "max-len": [ + "error", + { + "code": 80, + "tabWidth": 4 + } + ] + } +} diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 0000000..f5809ea --- /dev/null +++ b/.prettierignore @@ -0,0 +1,11 @@ +doc +public +.vscode +src/logo.svg +.drone.yml +.editorconfig +.gitignore +**/Dockerfile +docker-compose.yml +**/README*.md +package.json diff --git a/.prettierrc.json b/.prettierrc.json new file mode 100644 index 0000000..879164e --- /dev/null +++ b/.prettierrc.json @@ -0,0 +1,11 @@ +{ + "trailingComma": "es5", + "printWidth": 80, + "useTabs": false, + "tabWidth": 4, + "semi": true, + "singleQuote": false, + "jsxSingleQuote": false, + "jsxBracketSameLine": false, + "arrowParens": "always" +} diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..75f484e --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,7 @@ +{ + "files.eol": "\n", + "files.encoding": "utf8", + "files.insertFinalNewline": true, + "editor.tabSize": 4, + "editor.insertSpaces": true, +} diff --git a/README.md b/README.md deleted file mode 100644 index 897dc83..0000000 --- a/README.md +++ /dev/null @@ -1,44 +0,0 @@ -This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app). - -## Available Scripts - -In the project directory, you can run: - -### `npm start` - -Runs the app in the development mode.
-Open [http://localhost:3000](http://localhost:3000) to view it in the browser. - -The page will reload if you make edits.
-You will also see any lint errors in the console. - -### `npm test` - -Launches the test runner in the interactive watch mode.
-See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information. - -### `npm run build` - -Builds the app for production to the `build` folder.
-It correctly bundles React in production mode and optimizes the build for the best performance. - -The build is minified and the filenames include the hashes.
-Your app is ready to be deployed! - -See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information. - -### `npm run eject` - -**Note: this is a one-way operation. Once you `eject`, you can’t go back!** - -If you aren’t satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project. - -Instead, it will copy all the configuration files and the transitive dependencies (Webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own. - -You don’t have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it. - -## Learn More - -You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started). - -To learn React, check out the [React documentation](https://reactjs.org/). diff --git a/package.json b/package.json index 38f11c8..62daf17 100644 --- a/package.json +++ b/package.json @@ -1,36 +1,33 @@ { - "name": "notes_web", - "version": "0.1.0", - "private": true, - "dependencies": { - "@types/jest": "24.0.18", - "@types/node": "12.7.2", - "@types/react": "16.9.2", - "@types/react-dom": "16.9.0", - "react": "^16.9.0", - "react-dom": "^16.9.0", - "react-scripts": "3.1.1", - "typescript": "3.5.3" - }, - "scripts": { - "start": "react-scripts start", - "build": "react-scripts build", - "test": "react-scripts test", - "eject": "react-scripts eject" - }, - "eslintConfig": { - "extends": "react-app" - }, - "browserslist": { - "production": [ - ">0.2%", - "not dead", - "not op_mini all" - ], - "development": [ - "last 1 chrome version", - "last 1 firefox version", - "last 1 safari version" - ] - } + "name": "notes_web", + "version": "0.1.0", + "private": true, + "dependencies": { + "@types/jest": "24.0.18", + "@types/node": "12.7.2", + "@types/react": "16.9.2", + "@types/react-dom": "16.9.0", + "react": "^16.9.0", + "react-dom": "^16.9.0", + "react-scripts": "3.1.1", + "typescript": "3.5.3" + }, + "scripts": { + "start": "react-scripts start", + "build": "react-scripts build", + "test": "react-scripts test", + "eject": "react-scripts eject" + }, + "browserslist": { + "production": [ + ">0.2%", + "not dead", + "not op_mini all" + ], + "development": [ + "last 1 chrome version", + "last 1 firefox version", + "last 1 safari version" + ] + } } diff --git a/tsconfig.json b/tsconfig.json index f2850b7..547e032 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,25 +1,25 @@ { - "compilerOptions": { - "target": "es5", - "lib": [ - "dom", - "dom.iterable", - "esnext" - ], - "allowJs": true, - "skipLibCheck": true, - "esModuleInterop": true, - "allowSyntheticDefaultImports": true, - "strict": true, - "forceConsistentCasingInFileNames": true, - "module": "esnext", - "moduleResolution": "node", - "resolveJsonModule": true, - "isolatedModules": true, - "noEmit": true, - "jsx": "react" - }, - "include": [ - "src" - ] + "compilerOptions": { + "target": "es5", + "lib": [ + "dom", + "dom.iterable", + "esnext" + ], + "allowJs": true, + "skipLibCheck": true, + "esModuleInterop": true, + "allowSyntheticDefaultImports": true, + "strict": true, + "forceConsistentCasingInFileNames": true, + "module": "esnext", + "moduleResolution": "node", + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "react" + }, + "include": [ + "src" + ] }