-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'release-candidate' into release
- Loading branch information
Showing
1,233 changed files
with
37,928 additions
and
33,398 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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,6 @@ | ||
# Modules | ||
node_modules/ | ||
|
||
# Test | ||
coverage/ | ||
|
||
# Build output | ||
build/ | ||
|
||
coverage/ |
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,129 +1,3 @@ | ||
const restrictedGlobals = require('confusing-browser-globals'); | ||
|
||
module.exports = { | ||
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, | ||
}, | ||
}, | ||
extends: ['jwp/typescript'], | ||
}; |
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.
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 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 |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: Web - Release - Deploy Prod Demo Site | ||
|
||
on: | ||
push: | ||
branches: ['release'] | ||
workflow_dispatch: | ||
|
||
defaults: | ||
run: | ||
working-directory: ./platforms/web | ||
|
||
jobs: | ||
deploy_live_website: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Build | ||
env: | ||
APP_PLAYER_LICENSE_KEY: ${{ secrets.PLAYER_LICENSE_KEY }} | ||
APP_GOOGLE_SITE_VERIFICATION_ID: ${{ vars.GOOGLE_SITE_VERIFICATION_ID }} | ||
run: yarn && MODE=demo yarn build | ||
- uses: FirebaseExtended/action-hosting-deploy@v0 | ||
with: | ||
repoToken: '${{ secrets.GITHUB_TOKEN }}' | ||
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT }}' | ||
channelId: live | ||
entryPoint: './platforms/web' |
39 changes: 39 additions & 0 deletions
39
.github/workflows/web-test-deploy-preview-and-lighthouse.yml
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 |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: Web - Test - PR Deploy Preview and Lighthouse Test | ||
|
||
on: | ||
pull_request: | ||
|
||
defaults: | ||
run: | ||
working-directory: ./platforms/web | ||
|
||
jobs: | ||
build_and_preview: | ||
name: Build and preview | ||
runs-on: ubuntu-latest | ||
outputs: | ||
output1: ${{ steps.firebase_hosting_preview.outputs.details_url }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Build Preview Link | ||
env: | ||
APP_PLAYER_LICENSE_KEY: ${{ secrets.PLAYER_LICENSE_KEY }} | ||
run: yarn && MODE=preview yarn build | ||
- uses: FirebaseExtended/action-hosting-deploy@v0 | ||
id: firebase_hosting_preview | ||
with: | ||
entryPoint: './platforms/web' | ||
repoToken: '${{ secrets.GITHUB_TOKEN }}' | ||
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT }}' | ||
expires: 30d | ||
|
||
lhci: | ||
name: Lighthouse | ||
runs-on: ubuntu-latest | ||
needs: build_and_preview | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Install Lighthouse CI | ||
run: sudo yarn global add @lhci/cli@0.12.x | ||
- name: Run Lighthouse CI | ||
run: lhci autorun --collect.url=${{ needs.build_and_preview.outputs.output1 }}?app-config=gnnuzabk --config=./lighthouserc.cjs |
Oops, something went wrong.