Skip to content

lifeilu/react-mf-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

intruction

A demo of two react projects use webpack module federation

source structure

  • reactA: the project of reactA
  • reactB: the project of reactB

more details:

  1. reactA mf config
reactA\config\mf-config.js
  1. reactA component use reactB component
reactA\src\app.js
  1. reactB mf config
reactB\config\mf-config.js
  1. reactB component source code
reactB\src\button.js
  1. reactB component use reactB component in the same project
reactB\src\app.js

how to start

cd reactB
npm install
npm start

cd reactA
npm install
npm start

result

the component in reactB

the component used in reactA

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published