-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "feat(project)!: restructure for multiplatforms with workspaces (
- Loading branch information
1 parent
7464def
commit 3058141
Showing
893 changed files
with
10,586 additions
and
10,505 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,30 @@ | ||
ignores: [ | ||
# These are dependencies for vite and vite plugins that depcheck doesn't recognize as being used | ||
'postcss-scss', | ||
'stylelint-order', | ||
'stylelint-config-recommended-scss', | ||
'stylelint-declaration-strict-value', | ||
'stylelint-scss', | ||
'@vitest/coverage-v8', | ||
# This is used by commitlint in .commitlintrc.js | ||
'@commitlint/config-conventional', | ||
|
||
# @todo: remove dep from main package, once i18next is moved to specific packages | ||
'ts-node', | ||
|
||
# Workspace packages | ||
'eslint-config-jwp', | ||
'@typescript-eslint/parser', # Required by eslint-config-jwp | ||
'@typescript-eslint/eslint-plugin', # Required by eslint-config-jwp | ||
'eslint-plugin-import', # Required by eslint-config-jwp | ||
|
||
'depcheck', | ||
'ts-node' | ||
# These are vite aliases / tsconfig paths that point to specific local directories | ||
# Note the \ is necessary to escape the # or the ignore doesn't work | ||
'\#src', | ||
'\#test', | ||
'\#types', | ||
'\#components', | ||
'\#utils', | ||
'src', # This is used in src/styles, which recognizes absolute paths from the repo root | ||
'allure-commandline', # To support e2e-reports | ||
'@codeceptjs/allure-legacy', | ||
'faker', | ||
'i18next-parser', # For extracting i18next translation keys | ||
'npm-run-all', # To run linting checks | ||
'virtual:pwa-register', # Service Worker code is injected at build time | ||
'vite-plugin-pwa/client', # Used to generate pwa framework | ||
'reflect-metadata', # Used for ioc resolution | ||
'@babel/plugin-proposal-decorators', # Used to build with decorators for ioc resolution | ||
'babel-plugin-transform-typescript-metadata', # Used to build with decorators for ioc resolution | ||
'@babel/core', # Required peer dependency for babel plugins above | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
# Modules | ||
node_modules/ | ||
|
||
build/ | ||
|
||
# Test | ||
coverage/ | ||
|
||
# Build output | ||
build/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,129 @@ | ||
const restrictedGlobals = require('confusing-browser-globals'); | ||
|
||
module.exports = { | ||
extends: ['jwp/typescript'], | ||
parser: '@typescript-eslint/parser', | ||
|
||
plugins: [ | ||
// Enable Typescript linting | ||
'@typescript-eslint', | ||
|
||
// Enable linting imports | ||
'import', | ||
], | ||
|
||
extends: [ | ||
// Use default ESLint rules | ||
'eslint:recommended', | ||
|
||
// Use recommended TS rules | ||
'plugin:@typescript-eslint/recommended', | ||
|
||
// Use recommended React rules | ||
'plugin:react/recommended', | ||
|
||
'plugin:import/errors', | ||
'plugin:import/warnings', | ||
'plugin:import/typescript', | ||
], | ||
|
||
env: { | ||
// Browser conf | ||
browser: true, | ||
es6: true, | ||
}, | ||
|
||
rules: { | ||
// Prevent development/debugging statements | ||
'no-console': ['error', { allow: ['warn', 'error', 'info', 'debug'] }], | ||
'no-alert': 'error', | ||
'no-debugger': 'error', | ||
|
||
// Prevent usage of confusing globals | ||
'no-restricted-globals': ['error'].concat(restrictedGlobals), | ||
|
||
// Assignments in function returns is confusing and could lead to unwanted side-effects | ||
'no-return-assign': ['error', 'always'], | ||
|
||
curly: ['error', 'multi-line'], | ||
|
||
// Strict import ordering | ||
'import/order': [ | ||
'warn', | ||
{ | ||
groups: ['builtin', 'external', 'parent', 'sibling', 'index'], | ||
pathGroups: [ | ||
// Sort absolute root imports before parent imports | ||
{ | ||
pattern: '/**', | ||
group: 'parent', | ||
position: 'before', | ||
}, | ||
], | ||
'newlines-between': 'always', | ||
}, | ||
], | ||
// Not needed in React 17 | ||
'react/react-in-jsx-scope': 'off', | ||
'import/no-named-as-default-member': 'off', | ||
}, | ||
overrides: [ | ||
{ | ||
files: ['*.js'], | ||
env: { | ||
// We may still use CJS in .js files (eg. local scripts) | ||
commonjs: true, | ||
}, | ||
rules: { | ||
// `require` is still allowed/recommended in JS | ||
'@typescript-eslint/no-var-requires': 'off', | ||
}, | ||
}, | ||
{ | ||
files: ['*.ts', '*.tsx'], | ||
rules: { | ||
// TypeScript 4.0 adds 'any' or 'unknown' type annotation on catch clause variables. | ||
// We need to make sure error is of the type we are expecting | ||
'@typescript-eslint/no-implicit-any-catch': 'error', | ||
|
||
// These are handled by TS | ||
'@typescript-eslint/no-explicit-any': ['warn', { ignoreRestArgs: true }], | ||
'@typescript-eslint/explicit-module-boundary-types': 'off', | ||
'@typescript-eslint/no-inferrable-types': 'off', | ||
'@typescript-eslint/ban-ts-comment': 'off', | ||
'@typescript-eslint/no-unused-vars': 'off', | ||
'import/no-unresolved': 'off', | ||
}, | ||
}, | ||
{ | ||
files: ['*.jsx', '*.tsx', 'src/hooks/*.ts'], | ||
plugins: [ | ||
// Enable linting React code | ||
'react', | ||
'react-hooks', | ||
], | ||
rules: { | ||
// Help with Hooks syntax | ||
'react-hooks/rules-of-hooks': 'error', | ||
'react-hooks/exhaustive-deps': 'error', | ||
|
||
// Handled by Typescript | ||
'react/prop-types': 'off', | ||
|
||
// This rule causes too many false positives, eg. with default exports or child render function | ||
'react/display-name': 'off', | ||
}, | ||
}, | ||
], | ||
|
||
settings: { | ||
react: { | ||
pragma: 'React', | ||
version: '17', | ||
}, | ||
}, | ||
parserOptions: { | ||
ecmaFeatures: { | ||
jsx: true, | ||
}, | ||
}, | ||
}; |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,26 @@ | ||
# project, build, and deployment | ||
node_modules | ||
build | ||
.snowpack | ||
coverage | ||
output | ||
public/locales/**/*_old.json | ||
yarn-error.log | ||
.firebase | ||
firebase-debug.log | ||
.stylelintcache | ||
.lighthouseci | ||
|
||
# os or editor | ||
.idea | ||
.DS_Store | ||
.vscode/ | ||
|
||
# ignore local files | ||
*.local | ||
|
||
# Exclude ini files because they have customer specific data | ||
ini/*.ini | ||
|
||
# Ignore working area for i18n checks | ||
.temp-translations |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.