Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/develop' into release/4.0.0-be…
Browse files Browse the repository at this point in the history
…ta.10
  • Loading branch information
ptchayap committed Jul 24, 2024
2 parents f5f580a + 9357565 commit ca6da7d
Show file tree
Hide file tree
Showing 83 changed files with 6,258 additions and 4,292 deletions.
7 changes: 4 additions & 3 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
STORYBOOK_API_REGION=
# Please use comma to separate userIds example User1,User2,User3
STORYBOOK_USERS=
STORYBOOK_API_KEY=
STORYBOOK_USER1=
STORYBOOK_USER2=
# eu, sg, us
STORYBOOK_API_REGION=
6 changes: 0 additions & 6 deletions .eslintignore

This file was deleted.

44 changes: 0 additions & 44 deletions .eslintrc.cjs

This file was deleted.

1 change: 0 additions & 1 deletion .github/workflows/dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ jobs:

- uses: pnpm/action-setup@v4
with:
version: 9
run_install: false

- name: Get pnpm store directory
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/production.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ jobs:
- uses: pnpm/action-setup@v4
with:
version: 9
run_install: false

- name: Get pnpm store directory
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/staging.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ jobs:

- uses: pnpm/action-setup@v4
with:
version: 9
run_install: false

- name: Get pnpm store directory
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/testing.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ jobs:

- uses: pnpm/action-setup@v4
with:
version: 9
run_install: false

- name: Get pnpm store directory
Expand Down
74 changes: 74 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
// @ts-check

import jest from 'eslint-plugin-jest';

import globals from 'globals';
import js from '@eslint/js';
import tseslint from 'typescript-eslint';
import eslintPluginPrettierRecommended from 'eslint-plugin-prettier/recommended';

const ignores = [
'**/node_modules',
'**/storybook-build',
'**/build',
'**/dist',
'**/jest.config.js',
// Ignore build artifacts
'**/build',
'**/coverage',
'**/node_modules',
];

export default [
js.configs.recommended,
...tseslint.configs.recommended,
{
languageOptions: {
globals: {
...globals.browser,
...globals.node,
...globals.jest,
},
},
rules: {
'@typescript-eslint/no-empty-function': 'off',
'import/no-named-as-default': 'off',
'import/no-named-as-default-member': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-unused-vars': 'off',
'@typescript-eslint/ban-ts-comment': 'off',
},
},
{
files: ['**/*.{test,spec}.{ts,tsx}'],
ignores,
...jest.configs['flat/recommended'],
rules: {
...jest.configs['flat/recommended'].rules,
'jest/prefer-expect-assertions': 'off',
},
},
{
files: ['src/v4/**/*.{ts,tsx}'],
ignores,
rules: {
'no-restricted-imports': [
'error',
{
patterns: [
{
group: ['../'],
message: 'Relative imports are not allowed.',
},
{
group: ['**/*/index'],
message: 'index imports are not allowed.',
},
],
},
],
},
},
eslintPluginPrettierRecommended,
{ ignores },
];
17 changes: 11 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
},
"devDependencies": {
"@amityco/ts-sdk": "^6.27.0",
"@eslint/js": "^9.4.0",
"@storybook/addon-a11y": "^7.6.7",
"@storybook/addon-actions": "^7.6.7",
"@storybook/addon-backgrounds": "^7.6.7",
Expand All @@ -57,6 +58,7 @@
"@storybook/react": "^7.6.7",
"@storybook/react-vite": "^7.6.7",
"@storybook/theming": "^7.6.7",
"@types/eslint__js": "^8.42.3",
"@types/jest": "^29.5.11",
"@types/lodash": "^4.14.202",
"@types/prop-types": "^15.7.11",
Expand All @@ -74,16 +76,16 @@
"autoprefixer": "^10.4.19",
"browserslist": "^4.23.0",
"esbuild-plugin-replace": "^1.4.0",
"eslint": "^8.56.0",
"eslint": "^9.4.0",
"eslint-config-prettier": "^9.1.0",
"eslint-import-resolver-typescript": "^3.6.1",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-jest": "^27.6.1",
"eslint-plugin-prettier": "^5.1.3",
"globals": "^15.4.0",
"husky": "^8.0.3",
"jest": "^29.7.0",
"lint-staged": "^13.3.0",
"postcss": "^8.4.38",
"prettier": "2.4.0",
"prettier": "3.3.1",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-router-dom": "^6.21.1",
Expand All @@ -97,6 +99,7 @@
"ts-jest": "^29.1.1",
"tsup": "^7.3.0",
"typescript": "^4.9.5",
"typescript-eslint": "^7.12.0",
"typescript-plugin-css-modules": "^5.1.0",
"vite": "^4.5.1",
"vite-tsconfig-paths": "^4.2.3"
Expand Down Expand Up @@ -140,19 +143,21 @@
"react-truncate-markup": "^5.1.2",
"react-use": "^17.4.2",
"stylis": "^4.3.1",
"typescript-eslint": "^7.17.0",
"uuid": "^8.3.2",
"vaul": "^0.9.1",
"zod": "^3.22.4"
},
"lint-staged": {
"*.{js,jsx,ts,tsx}": "eslint --cache --fix",
"*.{json,md,css}": "prettier --write",
"*.{json,css}": "prettier --write",
"*.{css}": "stylelint --fix"
},
"postcss": {
"plugins": {
"autoprefixer": {}
}
},
"license": "LGPL-2.1-only"
"license": "LGPL-2.1-only",
"packageManager": "pnpm@9.5.0"
}
Loading

0 comments on commit ca6da7d

Please sign in to comment.