Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
d0a11ff
feat(bridge-react): support react v19 in react compat file
danpeen Mar 31, 2025
86159eb
chore: merge main branch
danpeen Mar 31, 2025
9998099
feat(bridge-react): add react v19 example
danpeen Mar 31, 2025
625ae35
feat(bridge-react): wip 集测问题待修
danpeen Mar 31, 2025
bbf87c7
feat(bridge-react): add react 19 example and optimize bridge e2e tests
danpeen Apr 1, 2025
d802e00
feat(bridge-react): add native support for React 19 in bridge-react w…
danpeen Apr 1, 2025
bc472f3
chore: update bridge-react e2e tests
danpeen Apr 1, 2025
69a4712
chore: update
danpeen Apr 1, 2025
d834916
chore: fix router-demo e2e error
danpeen Apr 1, 2025
b21c9c2
chore: delete watch mode
danpeen Apr 1, 2025
cdd4217
Merge branch 'main' into feat/react-bridge-compat-reactv19
danpeen Apr 1, 2025
58eb93e
chore: merge branch 'main' into feat/react-bridge-compat-reactv19
danpeen Apr 1, 2025
7b3ed4f
Merge branch 'feat/react-bridge-compat-reactv19' of https://github.co…
danpeen Apr 1, 2025
bfdf047
feat: export different entry point for different react versions for c…
danpeen Apr 10, 2025
aae29c0
refactor(bridge-react): rename v16 to legacy and improve React versio…
danpeen Apr 10, 2025
849ca44
chore(website): update docs for bridge
danpeen Apr 10, 2025
2700c88
chore(website): update bridge docs
danpeen Apr 11, 2025
aea5f9e
chore: merge main branch and fix conflict
danpeen Apr 11, 2025
71cfc9b
chore: delete useless code
danpeen Apr 14, 2025
9e70ef8
chore: update bridge supporting react versions in bridge docs
danpeen Apr 15, 2025
d4b618c
fix: set @module-federation/bridge-react/plugin cjs entry point to pl…
danpeen Apr 16, 2025
3ae6fdd
chore: merge main branch
danpeen Apr 16, 2025
1ecdeba
chore: reset changes
danpeen Apr 16, 2025
2bab3ad
chore: merge branch 'main' into feat/react-bridge-compat-reactv19
danpeen Apr 16, 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
5 changes: 5 additions & 0 deletions .changeset/breezy-cats-give.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@module-federation/bridge-react': patch
---

feat(bridge-react): support react v19 in react compat file.
7 changes: 7 additions & 0 deletions .changeset/smart-snails-scream.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
'remote5': minor
'@module-federation/bridge-react': minor
'website-new': minor
---

feat(react-bridge): Add native support for React 19 in bridge-react with enhanced createRoot options
4 changes: 1 addition & 3 deletions apps/router-demo/router-host-2000/cypress/e2e/host.cy.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
import { getH2, getH3 } from '../support/app.po';

describe('router-host-2000/', () => {
beforeEach(() => cy.visit('/'));

describe('Welcome message', () => {
it('should display welcome message', () => {
getH2().contains('Router host Home page');
cy.verifyContent('Router host Home page');
});
});
});
27 changes: 14 additions & 13 deletions apps/router-demo/router-host-2000/cypress/e2e/memory-router.cy.ts
Original file line number Diff line number Diff line change
@@ -1,37 +1,38 @@
import { getH2, getP, getPre } from '../support/app.po';

describe('router-host-2000/', () => {
beforeEach(() => cy.visit('/'));

describe('Welcome message', () => {
it('should display welcome message', () => {
getH2().contains('Router host Home page');
cy.verifyContent('Router host Home page');
});
});
});

describe('router-host-2000/memory-router', () => {
beforeEach(() => {
cy.visit('/');
cy.get('.host-menu > li:nth-child(6)').click();
cy.clickMenuItem('Memory-router');
});

describe('memory-router', () => {
Cypress.on('uncaught:exception', () => false);

it('remote1', () => {
getH2().contains('Remote1 home page');
cy.get('.self-remote1-detail-link').click();
getH2().contains('Remote1 detail page');
cy.verifyContent('Remote1 home page');
cy.clickByClass('.self-remote1-detail-link');
cy.verifyContent('Remote1 detail page');
});

it('remote2', () => {
getH2().contains('Remote2 detail page');
cy.get('.self-remote2-home-link').click();
getH2().contains('Remote2 home page');
cy.verifyContent('Remote2 detail page');
cy.clickByClass('.self-remote2-home-link');
cy.verifyContent('Remote2 home page');
});

it('remote3', () => {
getH2().contains('Remote3 home page');
cy.get('.self-remote3-detail-link').click();
getH2().contains('Remote3 detail page');
cy.verifyContent('Remote3 home page');
cy.clickByClass('.self-remote3-detail-link');
cy.verifyContent('Remote3 detail page');
});
});
});
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { getPre, getP } from '../support/app.po';

describe('router-remote-error in host', () => {
beforeEach(() => cy.visit('/'));

describe('Remote Error render and will trigger ErrorBoundary', () => {
Cypress.on('uncaught:exception', () => false);

it('jump to remote error page', () => {
cy.get('.host-menu > li:nth-child(7)').click();
getP().contains('Something went wrong');
getPre().contains('This is a deliberately thrown error');
cy.clickMenuItem('render-error');
cy.verifyContent('Something went wrong');
cy.verifyContent('This is a deliberately thrown error');
});
});
});
Original file line number Diff line number Diff line change
@@ -1,23 +1,16 @@
import { wait5s, getP, getPre } from '../support/app.po';

describe('router-remote-error in host', () => {
beforeEach(() => cy.visit('/'));

describe('Remote Resource Error render and will trigger ErrorBoundary', () => {
Cypress.on('uncaught:exception', () => false);
it('jump to remote error page', async () => {
cy.get('.host-menu > li:nth-child(8)').click({ force: true });

cy.get('[data-test-id="loading"]').should('have.length', 1);
cy.get('[data-test-id="loading"]')
.first()
.should('have.text', 'loading...');

await wait5s();
getP().contains('Something went wrong');
getPre().contains(
'The request failed three times and has now been abandoned',
);
it('jump to remote error page', () => {
cy.clickMenuItem('resource-error');
cy.checkLoading('[data-test-id="loading"]', 'loading...', 5000);
cy.verifyContent('Something went wrong');
// cy.verifyContent(
// 'The request failed three times and has now been abandoned',
// );
});
});
});
26 changes: 11 additions & 15 deletions apps/router-demo/router-host-2000/cypress/e2e/remote1.cy.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
import { getH2, getH3, getH4, wait2s } from '../support/app.po';

describe('router-remote1-2001/', () => {
beforeEach(() => cy.visit('http://localhost:2001/'));

describe('visit', () => {
it('jump to home page', () => {
getH2().contains('Remote1 home page');
cy.get('.self-remote1-detail-link').click();
getH2().contains('Remote1 detail page');
cy.verifyContent('Remote1 home page');
cy.clickByClass('.self-remote1-detail-link');
cy.verifyContent('Remote1 detail page');
});
});
});
Expand All @@ -17,16 +15,14 @@ describe('router-remote1-2001 in host', () => {

describe('Remote1 render and destroy', () => {
it('jump to remote1 home page', () => {
cy.get('.host-menu > li:nth-child(3)').click();
cy.get('.menu-remote1-home-link').click();

getH2().contains('Remote1 home page');
getH3().contains('Ming');
getH3().contains('12');
getH4().contains('Some text');

cy.get('.menu-remote1-detail-link').click();
getH2().contains('Remote1 detail page');
cy.clickMenuItem('Remote1');
cy.clickByClass('.menu-remote1-home-link');
cy.verifyContent('Remote1 home page');
cy.verifyContent('Ming');
cy.verifyContent('12');
cy.verifyContent('Some text');
cy.clickByClass('.menu-remote1-detail-link');
cy.verifyContent('Remote1 detail page');
});
});
});
19 changes: 8 additions & 11 deletions apps/router-demo/router-host-2000/cypress/e2e/remote2.cy.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
import { getH2, getH3, wait2s } from '../support/app.po';

describe('router-remote2-2002/', () => {
beforeEach(() => cy.visit('http://localhost:2002/'));

describe('visit', () => {
it('jump to home page', () => {
getH2().contains('Remote2 home page');
cy.get('.self-remote2-detail-link').click();
getH2().contains('Remote2 detail page');
cy.verifyContent('Remote2 home page');
cy.clickByClass('.self-remote2-detail-link');
cy.verifyContent('Remote2 detail page');
});
});
});
Expand All @@ -17,12 +15,11 @@ describe('router-remote2-2002 in host', () => {

describe('Remote2 render and destroy', () => {
it('jump to remote2 home page', () => {
cy.get('.host-menu > li:nth-child(4)').click();
cy.get('.menu-remote2-home-link').click();

getH2().contains('Remote2 home page');
cy.get('.menu-remote2-detail-link').click();
getH2().contains('Remote2 detail page');
cy.clickMenuItem('Remote2');
cy.clickByClass('.menu-remote2-home-link');
cy.verifyContent('Remote2 home page');
cy.clickByClass('.menu-remote2-detail-link');
cy.verifyContent('Remote2 detail page');
});
});
});
19 changes: 8 additions & 11 deletions apps/router-demo/router-host-2000/cypress/e2e/remote3.cy.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
import { getH2, getH3, wait2s } from '../support/app.po';

describe('router-remote3-2003/', () => {
beforeEach(() => cy.visit('http://localhost:2003/'));

describe('visit', () => {
it('jump to home page', () => {
getH2().contains('Remote3 home page');
cy.get('.self-remote3-detail-link').click();
getH2().contains('Remote3 detail page');
cy.verifyContent('Remote3 home page');
cy.clickByClass('.self-remote3-detail-link');
cy.verifyContent('Remote3 detail page');
});
});
});
Expand All @@ -17,12 +15,11 @@ describe('router-remote3-2003 in host', () => {

describe('Remote3 render and destroy', () => {
it('jump to remote3 home page', () => {
cy.get('.host-menu > li:nth-child(5)').click();
cy.get('.menu-remote3-home-link').click();

getH2().contains('Remote3 home page');
cy.get('.menu-remote3-detail-link').click();
getH2().contains('Remote3 detail page');
cy.clickMenuItem('Remote3');
cy.clickByClass('.menu-remote3-home-link');
cy.verifyContent('Remote3 home page');
cy.clickByClass('.menu-remote3-detail-link');
cy.verifyContent('Remote3 detail page');
});
});
});
20 changes: 20 additions & 0 deletions apps/router-demo/router-host-2000/cypress/e2e/remote5.cy.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
describe('router-remote5-2005/', () => {
beforeEach(() => cy.visit('http://localhost:2005/'));

describe('visit', () => {
it('should display React 19 content', () => {
cy.verifyContent('This is the remote app5 with React 19');
});
});
});

describe('router-remote5-2005 in host', () => {
beforeEach(() => cy.visit('/'));

describe('Remote5 render and destroy', () => {
it('jump to remote5 home page', () => {
cy.clickMenuItem('remote5');
cy.verifyContent('This is the remote app5 with React 19');
});
});
});
Loading
Loading