From bccfaf6e0ecf2804677ce3e2e14c076b80f830cf Mon Sep 17 00:00:00 2001 From: Philippe Bron Date: Sat, 17 Oct 2020 10:48:33 +0200 Subject: [PATCH] fixes load effect --- .babelrc | 10 +++ .editorconfig | 18 +++++ .eslintrc.js | 33 ++++++++ .gitignore | 213 +++++++++++++++++++++++++++++++++++++++++++++++++ .prettierrc.js | 4 + package.json | 2 - 6 files changed, 278 insertions(+), 2 deletions(-) create mode 100644 .babelrc create mode 100644 .editorconfig create mode 100644 .eslintrc.js create mode 100644 .gitignore create mode 100644 .prettierrc.js diff --git a/.babelrc b/.babelrc new file mode 100644 index 0000000..8924f68 --- /dev/null +++ b/.babelrc @@ -0,0 +1,10 @@ +{ + "presets": [ + "@babel/preset-env" + ], + "plugins": [ + ["@babel/plugin-transform-runtime", { + "regenerator": true + }] + ] +} diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..3fd4319 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,18 @@ +root = true + +[*] +charset = utf-8 +trim_trailing_whitespace = false +insert_final_newline = true +end_of_line = lf + +[*.html] +indent_style = space +indent_size = 2 + +[*.{js,json,yml}] +indent_style = space +indent_size = 2 + +[*.js] +quote_type = single diff --git a/.eslintrc.js b/.eslintrc.js new file mode 100644 index 0000000..6a307b5 --- /dev/null +++ b/.eslintrc.js @@ -0,0 +1,33 @@ +module.exports = { + root: true, + env: { + node: true, + browser: true, + }, + extends: ["standard"], + rules: { + "no-console": process.env.NODE_ENV === "production" ? "error" : "off", + "no-debugger": process.env.NODE_ENV === "production" ? "error" : "off", + "comma-dangle": [2, "always-multiline"], + "no-var": 2, + }, + overrides: [ + { + files: ["**/__tests__/*.js", "**/tests/unit/**/*.spec.js"], + env: { + jest: true + } + } + ], + parserOptions: { + parser: "babel-eslint" + }, + overrides: [ + { + files: ["**/__tests__/*.js", "**/tests/unit/**/*.spec.js"], + env: { + jest: true + } + } + ] +}; diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..4b49537 --- /dev/null +++ b/.gitignore @@ -0,0 +1,213 @@ + +# Created by https://www.toptal.com/developers/gitignore/api/node,code,linux,vim,windows,macos +# Edit at https://www.toptal.com/developers/gitignore?templates=node,code,linux,vim,windows,macos + +### Code ### +.vscode/* +!.vscode/settings.json +!.vscode/tasks.json +!.vscode/launch.json +!.vscode/extensions.json +*.code-workspace + +### Linux ### +*~ + +# temporary files which can be created if a process still has a handle open of a deleted file +.fuse_hidden* + +# KDE directory preferences +.directory + +# Linux trash folder which might appear on any partition or disk +.Trash-* + +# .nfs files are created when an open file is removed but is still being accessed +.nfs* + +### macOS ### +# General +.DS_Store +.AppleDouble +.LSOverride + +# Icon must end with two \r +Icon + +# Thumbnails +._* + +# Files that might appear in the root of a volume +.DocumentRevisions-V100 +.fseventsd +.Spotlight-V100 +.TemporaryItems +.Trashes +.VolumeIcon.icns +.com.apple.timemachine.donotpresent + +# Directories potentially created on remote AFP share +.AppleDB +.AppleDesktop +Network Trash Folder +Temporary Items +.apdisk + +### Node ### +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +lerna-debug.log* + +# Diagnostic reports (https://nodejs.org/api/report.html) +report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json + +# Runtime data +pids +*.pid +*.seed +*.pid.lock + +# Directory for instrumented libs generated by jscoverage/JSCover +lib-cov + +# Coverage directory used by tools like istanbul +coverage +*.lcov + +# nyc test coverage +.nyc_output + +# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) +.grunt + +# Bower dependency directory (https://bower.io/) +bower_components + +# node-waf configuration +.lock-wscript + +# Compiled binary addons (https://nodejs.org/api/addons.html) +build/Release + +# Dependency directories +node_modules/ +jspm_packages/ + +# TypeScript v1 declaration files +typings/ + +# TypeScript cache +*.tsbuildinfo + +# Optional npm cache directory +.npm + +# Optional eslint cache +.eslintcache + +# Microbundle cache +.rpt2_cache/ +.rts2_cache_cjs/ +.rts2_cache_es/ +.rts2_cache_umd/ + +# Optional REPL history +.node_repl_history + +# Output of 'npm pack' +*.tgz + +# Yarn Integrity file +.yarn-integrity + +# dotenv environment variables file +.env +.env.test +.env*.local + +# parcel-bundler cache (https://parceljs.org/) +.cache +.parcel-cache + +# Next.js build output +.next + +# Nuxt.js build / generate output +.nuxt +dist + +# Gatsby files +.cache/ +# Comment in the public line in if your project uses Gatsby and not Next.js +# https://nextjs.org/blog/next-9-1#public-directory-support +# public + +# vuepress build output +.vuepress/dist + +# Serverless directories +.serverless/ + +# FuseBox cache +.fusebox/ + +# DynamoDB Local files +.dynamodb/ + +# TernJS port file +.tern-port + +# Stores VSCode versions used for testing VSCode extensions +.vscode-test + +### Vim ### +# Swap +[._]*.s[a-v][a-z] +!*.svg # comment out if you don't need vector files +[._]*.sw[a-p] +[._]s[a-rt-v][a-z] +[._]ss[a-gi-z] +[._]sw[a-p] + +# Session +Session.vim +Sessionx.vim + +# Temporary +.netrwhist +# Auto-generated tag files +tags +# Persistent undo +[._]*.un~ + +### Windows ### +# Windows thumbnail cache files +Thumbs.db +Thumbs.db:encryptable +ehthumbs.db +ehthumbs_vista.db + +# Dump file +*.stackdump + +# Folder config file +[Dd]esktop.ini + +# Recycle Bin used on file shares +$RECYCLE.BIN/ + +# Windows Installer files +*.cab +*.msi +*.msix +*.msm +*.msp + +# Windows shortcuts +*.lnk + +# End of https://www.toptal.com/developers/gitignore/api/node,code,linux,vim,windows,macos diff --git a/.prettierrc.js b/.prettierrc.js new file mode 100644 index 0000000..55bfa8f --- /dev/null +++ b/.prettierrc.js @@ -0,0 +1,4 @@ +module.exports = { + singleQuote: true, + semi: false +}; diff --git a/package.json b/package.json index d0fd5ac..de35f8d 100644 --- a/package.json +++ b/package.json @@ -14,8 +14,6 @@ "build:simple": "cross-env-shell parcel build --public-url $PUBLIC_URL ./src/index.html ./src/robots.txt ./src/sitemap.xml", "build": "npm run build:dev", "postbuild": "cross-env-shell react-snap", - "build:prod": "cross-env PUBLIC_URL='/attestation-couvre-feu-covid-19' npm run build:simple", - "build:test": "cross-env PUBLIC_URL='/euqiremun' npm run build:simple", "build:dev": "cross-env PUBLIC_URL='/' npm run build:simple", "preserve": "npm run build", "serve": "serve dist",