Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

React 19 update #1632

Merged
merged 69 commits into from
Jan 24, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
69 commits
Select commit Hold shift + click to select a range
f40e124
feat: update @typescript-eslint/eslint-plugin to version 7.18.0 + add…
ThomasGross Jan 2, 2025
dde1e3f
update react and relevant dependencies
ThomasGross Jan 3, 2025
8095edd
Merge branch 'develop' into DDFNEXT-225-opgrader-typescript-eslint-es…
ThomasGross Jan 3, 2025
68c664f
fix: lint issues
ThomasGross Jan 3, 2025
b0911ba
fix: remove reach dialog sass styling
ThomasGross Jan 3, 2025
6e827f3
fix: build errors and warnings
ThomasGross Jan 3, 2025
8f149ed
fix: typescript issues
ThomasGross Jan 3, 2025
579b20a
fix: update eslint flags in pull request workflow
ThomasGross Jan 3, 2025
8284819
fix: unit tests and unit test specific config after react update
ThomasGross Jan 7, 2025
0b2f33e
fix: typescript issues
ThomasGross Jan 7, 2025
f966cd7
fix: update Storybook dependencies to latest versions
ThomasGross Jan 7, 2025
222770d
fix: remove browserify and add webpack as preprocessor to fix failing…
ThomasGross Jan 7, 2025
d907108
fix: rollback tsconfig
ThomasGross Jan 7, 2025
9994a03
fix: update eslint flags in pull request workflow for better JavaScri…
ThomasGross Jan 7, 2025
84a1c10
fix: update Cypress configuration to use ES module syntax
ThomasGross Jan 7, 2025
fcb1628
Merge branch 'develop' into react-19-update
ThomasGross Jan 7, 2025
9fd8b2e
fix: add updated yarn file
ThomasGross Jan 7, 2025
1083599
Merge branch 'develop' into react-19-update
ThomasGross Jan 7, 2025
b263945
fix: typescript issues in cypress test
ThomasGross Jan 7, 2025
5ac2641
fix: remove test files from TypeScript exclusion in tsconfig
ThomasGross Jan 7, 2025
7d774d5
update yarn.lock
ThomasGross Jan 7, 2025
9439a0f
fix: update ESLint configuration and convert PostCSS config to ES mod…
ThomasGross Jan 7, 2025
62eb2e5
fix: convert PostCSS config to CommonJS module syntax
ThomasGross Jan 7, 2025
b4b3a2d
fix: add @types/prop-types and update tsconfig include paths to fix t…
ThomasGross Jan 8, 2025
36db11d
fix: update ESLint flags in pull request workflow to include all Java…
ThomasGross Jan 8, 2025
9e2fb12
fix: reorder ESLint plugins
ThomasGross Jan 8, 2025
e64bd8b
fix: update ESLint flags in pull request workflow to target the src d…
ThomasGross Jan 8, 2025
678dec3
fix: convert Cypress config to ES module syntax
ThomasGross Jan 8, 2025
e30919c
fix: update markdown lint fix command
ThomasGross Jan 8, 2025
5a331d5
package.json cleanup
ThomasGross Jan 8, 2025
6ef7ac3
update mount function
ThomasGross Jan 8, 2025
2e8e239
fix: update React version detection in ESLint config
ThomasGross Jan 8, 2025
599e40e
fix: remove unused import path for CyHttpMessages
ThomasGross Jan 8, 2025
66db145
feat: add ESLint packages to Dependabot configuration
ThomasGross Jan 8, 2025
b2511dc
fix: remove airbnb config from Dependabot
ThomasGross Jan 8, 2025
db6a1fd
feat: add Cypress packages group to Dependabot configuration
ThomasGross Jan 8, 2025
f80b644
fix: update @storybook/addon-webpack5-compiler-babel to version 3.0.5
ThomasGross Jan 8, 2025
7edf960
fix: set @types/node to match project node version
ThomasGross Jan 8, 2025
9fc6285
fix: update happy-dom to version 16.3.0
ThomasGross Jan 8, 2025
2f674cc
fix: update typescript to version 5.7.2
ThomasGross Jan 8, 2025
ed54f20
fix: remove vitest from dependencies
ThomasGross Jan 8, 2025
68fc7ad
fix: clarify comment on enum value for earticle in ManifestationMater…
ThomasGross Jan 8, 2025
bea7082
fix: uncomment and fix erroneous requests test in useMultipleRequests…
ThomasGross Jan 8, 2025
b1458e5
fix: update import statement for createRoot from react-dom/client to …
ThomasGross Jan 8, 2025
dd5804a
fix: update import statement for createRoot from react-dom to react-d…
ThomasGross Jan 9, 2025
ddd2dcb
fix: update ESLint configuration to use eslint recommended instead of…
ThomasGross Jan 9, 2025
b9eb719
fix: update ESLint rules and update inflicted files accordingly
ThomasGross Jan 10, 2025
ce6bf90
fix: re-introduce no-console rule for debug statements but allow cons…
ThomasGross Jan 10, 2025
7819e25
remove unused jest setup file.
ThomasGross Jan 13, 2025
60485ac
fix: eslint lint all files instead of only linting inside the src and…
ThomasGross Jan 13, 2025
41ea2b2
refactor: convert CommonJS modules to ES6 imports/exports in code gen…
ThomasGross Jan 13, 2025
4c926a3
fix: disable no-console rule for logging replacement results in post-…
ThomasGross Jan 13, 2025
b0baec9
fix: roll back ESmodule to CommonJS to fix build phase
ThomasGross Jan 13, 2025
88c6cb1
fix: ignore all config js and mjs files in ESLint linting
ThomasGross Jan 13, 2025
785aac2
Merge branch 'develop' into react-19-update
ThomasGross Jan 13, 2025
7356ba1
update lock
ThomasGross Jan 13, 2025
0567ad6
fix: solve display name where its possible else leave a TODO
ThomasGross Jan 21, 2025
c415874
fix: solve display name where its possible else leave a TODO
ThomasGross Jan 21, 2025
e245530
refactor: add no alert to esconfig
ThomasGross Jan 22, 2025
8298276
refactor: re-introduce react/no-danger rule in eslint
ThomasGross Jan 22, 2025
0af4457
refactor: reintroduce react/jsx-props-no-spreading rule in eslint and…
ThomasGross Jan 22, 2025
cc73e3f
refactor: update eslint config to allow prop spreading in stories
ThomasGross Jan 22, 2025
94791ee
refactor: reintroduce import/no-cycle rule to eslint
ThomasGross Jan 22, 2025
2c4f7fd
refactor: add aria-label to modal backdrop button for improved access…
ThomasGross Jan 22, 2025
c591fd6
Merge branch 'develop' into react-19-update
ThomasGross Jan 22, 2025
bbfed14
feat: add updated yarn lock
ThomasGross Jan 22, 2025
c1446bf
fix: remove airbnb packages and update yarn lock
ThomasGross Jan 24, 2025
bf2c364
Merge branch 'develop' into react-19-update
ThomasGross Jan 24, 2025
7df1b85
fix: update ESLint rules with no-script-url and enforce error.log/war…
ThomasGross Jan 24, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions .eslintignore

This file was deleted.

152 changes: 0 additions & 152 deletions .eslintrc

This file was deleted.

18 changes: 18 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,3 +50,21 @@ updates:
testing-library:
patterns:
- "@testing-library/*"
eslint:
patterns:
- "eslint"
- "eslint-config-prettier"
- "eslint-loader"
- "eslint-plugin-cypress"
- "eslint-plugin-import"
- "eslint-plugin-jsx-a11y"
- "eslint-plugin-no-only-tests"
- "eslint-plugin-prettier"
- "eslint-plugin-react"
- "eslint-plugin-react-hooks"
- "eslint-webpack-plugin"
- "@eslint/*"
cypress:
patterns:
- "cypress"
- "@cypress/*"
Comment on lines +53 to +70
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 Nice. These are meaningful groups to add.

2 changes: 1 addition & 1 deletion .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ jobs:
with:
github_token: ${{ secrets.github_token }}
reporter: github-pr-check
eslint_flags: '--ext .js --ext .jsx ./src/'
eslint_flags: './src/'
- name: Lint Javascript
run: yarn lint:js

Expand Down
6 changes: 3 additions & 3 deletions cypress.config.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
// eslint-disable-next-line import/no-extraneous-dependencies
const { defineConfig } = require("cypress");
const plugins = require("./cypress/plugins");
import { defineConfig } from "cypress";
import plugins from "./cypress/plugins";

module.exports = defineConfig({
export default defineConfig({
projectId: "4trcdv",
defaultCommandTimeout: 10000,
pageLoadTimeout: 10000,
Expand Down
63 changes: 40 additions & 23 deletions cypress/plugins/index.js
Original file line number Diff line number Diff line change
@@ -1,28 +1,45 @@
// Cypress no longer natively supports plugins file, but we keep it for better code abstraction
// https://docs.cypress.io/app/references/migration-guide#Plugins-File-Removed
import task from "@cypress/code-coverage/task";
import webpackPreprocessor from "@cypress/webpack-preprocessor";

const task = require("@cypress/code-coverage/task");
const browserify = require("@cypress/browserify-preprocessor");

// In order to use both babelrc and typescript in browserify
// we copy the functionality from @cypress/code-coverage/use-babelrc
// and merge it with the typescript setting.
// The plugin @cypress/code-coverage/use-babelrc basically
// sets babelrc: true in the browserify options.
const { browserifyOptions } = browserify.defaultOptions;
browserifyOptions.transform[1][1].babelrc = true;

module.exports = (on, config) => {
export default (on, config) => {
task(on, config);
on(
"file:preprocessor",
browserify({
typescript: require.resolve("typescript"),
browserifyOptions: {
extensions: [".js", ".ts"],
...browserifyOptions

const options = {
webpackOptions: {
resolve: {
extensions: [".ts", ".tsx", ".js", ".jsx"],
modules: ["node_modules", "src"]
},
module: {
rules: [
{
test: /\.tsx?$/,
use: [
{
loader: "ts-loader",
options: {
transpileOnly: true,
compilerOptions: {
module: "esnext",
target: "es5",
lib: ["es5", "dom"],
jsx: "react",
allowJs: true,
esModuleInterop: true,
allowSyntheticDefaultImports: true,
noEmit: false
}
}
}
],
exclude: /node_modules/
}
]
}
})
);
}
};

on("file:preprocessor", webpackPreprocessor(options));

return config;
};
14 changes: 4 additions & 10 deletions cypress/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
{
"compilerOptions": {
"target": "es5",
"lib": [
"es5",
"dom"
],
"types": [
"cypress"
]
"lib": ["es5", "dom"],
"types": ["cypress"],
"allowJs": true
},
"include": [
"**/*.ts"
]
"include": ["**/*.ts"]
}
Loading
Loading