Skip to content

Commit 14d2c02

Browse files
committed
doc
1 parent 9c13cfb commit 14d2c02

File tree

4 files changed

+152
-85
lines changed

4 files changed

+152
-85
lines changed

README.md

Lines changed: 79 additions & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -1,105 +1,104 @@
1-
# Create Micro React App
1+
# Create Micro React App [![Build Status](https://travis-ci.com/matheusmr13/create-microfrontend-react-app.svg?branch=master)](https://travis-ci.com/matheusmr13/create-microfrontend-react-app) [![Build Status](https://dev.azure.com/matheusmr13/create-microfrontend-react-app/_apis/build/status/matheusmr13.create-microfrontend-react-app?branchName=master)](https://dev.azure.com/matheusmr13/create-microfrontend-react-app/_build/latest?definitionId=2&branchName=master) [![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=matheusmr13_create-microfrontend-react-app&metric=alert_status)](https://sonarcloud.io/dashboard?id=matheusmr13_create-microfrontend-react-app)
22

3-
[![Build Status](https://travis-ci.com/matheusmr13/create-microfrontend-react-app.svg?branch=master)](https://travis-ci.com/matheusmr13/create-microfrontend-react-app)
4-
[![Build Status](https://dev.azure.com/matheusmr13/create-microfrontend-react-app/_apis/build/status/matheusmr13.create-microfrontend-react-app?branchName=master)](https://dev.azure.com/matheusmr13/create-microfrontend-react-app/_build/latest?definitionId=2&branchName=master)
5-
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=matheusmr13_create-microfrontend-react-app&metric=alert_status)](https://sonarcloud.io/dashboard?id=matheusmr13_create-microfrontend-react-app)
3+
<img align="right" src="icon.png" width="23%">
64

7-
Create simple microfrontend architecture with tools like [Create React App](https://github.com/facebook/create-react-app).
5+
Most complete approach to microfrontend architecture:
86

9-
<p align="center">
10-
<img src="icon.svg" width="40%">
11-
</p>
7+
- Library to export and import microfrontends; [know more...](https://matheusmr13.github.io/create-micro-react-app/docs/core)
8+
- Command line interface to create, development and release your app; [know more...](https://matheusmr13.github.io/create-micro-react-app/docs/cli)
9+
- Backoffice to simplify all complexity needed; [know more...](https://matheusmr13.github.io/create-micro-react-app/docs/backoffice)
10+
- Simple just like [Create React App](https://github.com/facebook/create-react-app).
11+
12+
If you want to know more about microfrontends and why you should (or shouldn't) use it, check [this article](https://matheusmr13.github.io/create-micro-react-app/docs/core/microfrontend).
1213

1314
## Quick Overview
1415

1516
```
16-
npx @cmra/cli create my-app --app --microfrontend
17+
npx @cmra/cli create my-app
1718
cd my-app
1819
npm start
1920
```
2021

21-
## What it does
22-
23-
It helps you create a simple application with microfrontend architecture with no build configuration.
24-
25-
### Core Features
22+
## Installing
2623

27-
- Microfrontend development made easy:
24+
To install our cli you need **Node >= 13**.
2825

29-
- Boilerplate and pre configured architechture;
26+
### npm
3027

31-
- Mock all other microfrontends (refering to a stable environment) combined with hotreload on current microfrontend, allowing you to see the changes you make as you develop new feature on a specific module;
32-
33-
- Choose to split microfrontends into multiple repositories;
28+
```bash
29+
npm i -g @cmra/cli
30+
```
3431

35-
- You just need something to host your static files and you are ready to go with a microfrontend app;
32+
### yarn
3633

37-
- All of this with [Create React App](https://github.com/facebook/create-react-app) beautiful configuration.
34+
```bash
35+
yarn global add @cmra/cli
36+
```
3837

39-
- Integrates easy with a simple management interface that helps you organizing your microfrontends.
38+
## Using it
4039

41-
## Service
40+
After installing it, you'll have `cmra` command available:
4241

43-
Splited on marketplace-backend and marketplace-frontend packages.
42+
```
43+
cmra create my-app
44+
```
4445

45-
It helps you organizing your application integrated with the best tools (like github), like a backoffice for your architechtur.
46-
You can have a simple microfrontend architechture on your application, and deploy it easily with many options.
47-
Check our [site](https://matheusmr13.github.io/create-micro-react-app) for a demo.
46+
It will generate a folder structure like:
47+
48+
```bash
49+
my-app
50+
├── package.json
51+
├── packages
52+
| ├── microfrontend # create-react-app structure folder
53+
| | ├── README.md
54+
| | ├── package.json
55+
| | ├── public
56+
| | | ├── favicon.ico
57+
| | | ├── index.html
58+
| | | ├── logo192.png
59+
| | | ├── logo512.png
60+
| | | ├── manifest.json
61+
| | | └── robots.txt
62+
| | ├── src
63+
| | | ├── App.css
64+
| | | ├── App.js
65+
| | | ├── App.test.js
66+
| | | ├── index.css
67+
| | | ├── index.js
68+
| | | ├── logo.svg
69+
| | | ├── serviceWorker.js
70+
| | | └── setupTests.js
71+
| | └── yarn.lock
72+
| └── webapp # create-react-app structure folder
73+
| ├── README.md
74+
| ├── package.json
75+
| ├── public
76+
| | ├── favicon.ico
77+
| | ├── index.html
78+
| | ├── logo192.png
79+
| | ├── logo512.png
80+
| | ├── manifest.json
81+
| | ├── microfrontends
82+
| | | └── meta.json
83+
| | └── robots.txt
84+
| ├── src
85+
| | ├── App.css
86+
| | ├── App.js
87+
| | ├── App.test.js
88+
| | ├── index.css
89+
| | ├── index.js
90+
| | ├── logo.svg
91+
| | ├── serviceWorker.js
92+
| | └── setupTests.js
93+
| └── yarn.lock
94+
└── yarn.lock
95+
```
4896

49-
## CLI Docs
97+
## Development
5098

51-
Contained on @cmra/cli package.
99+
First of all, check our [contributing guide](https://github.com/matheusmr13/create-micro-react-app/blob/master/CONTRIBUTING.md).
100+
If you have any questions just [open an issue](https://github.com/matheusmr13/create-micro-react-app/issues/new)!
52101

53-
```
54-
npx @cmra/cli --help
55-
npx @cmra/cli start --help
56-
npx @cmra/cli build --help
57-
npx @cmra/cli create --help
58-
```
102+
---
59103

60104
Icon made by [Freepik](https://www.flaticon.com/authors/freepik) from [www.flaticon.com](https://www.flaticon.com/)
61-
62-
## Next steps
63-
64-
- Rename packages
65-
- Create "cmra" namespace
66-
- @cmra/cli -> "@cmra/cli"
67-
- react-microfrontend -> "@cmra/lib"
68-
- marketplace-frontend -> "@cmra/web"
69-
- marketplace-backend -> "@cmra/server"
70-
- export models from backend -> "@cmra/model"
71-
- Make it easy to deploy
72-
- server -> create package to extend -> `import Server from '@cmra/server'; Server.run();`
73-
- frontend -> create package to extend -> `import Webapp from '@cmra/web'; await Webapp.build(); Server.addStatic('build');`
74-
- docker image with all together
75-
- Permission
76-
- get things separate between users (currently works if you create your own environment)
77-
- Deploy
78-
- Schedule deploy to date
79-
- Recurrent deploy
80-
- Integrations to publish final package to:
81-
- Amazon s3
82-
- Package management integration, get packages from:
83-
- NPM
84-
- Amazon s3
85-
- Gitlab?
86-
- Extends command line
87-
- Application template (create-micro-react-app --from <APPLICATION_UUID>)
88-
- CLI for general uses such as preparing a next deploy
89-
- Flux between multiple namespaces
90-
- Define an order for each namespace (such as alpha->beta->main)
91-
- Expand namespaces
92-
- Create hidden "next deploy preview"
93-
- Integrate react-microfrontend with setting namespaces
94-
- Custom microfrontends
95-
- Set microfrontends meta infos (nav bar label? url? custom field)
96-
- Lazy loading
97-
- Changelog by version ()
98-
- Notifications
99-
- Changes to next deploy on namespace
100-
- Next deploy started (and done)
101-
- Integrations:
102-
- slack
103-
- email
104-
- Cannary deploy Vs Quality checks
105-
- Define some rules to get things checked and move to next deploy (really next to flux iniciative)

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@
1515
"test": "lerna run --stream --concurrency=1 test",
1616
"postinstall": "yarn lerna-bootstrap",
1717
"lerna-bootstrap": "lerna bootstrap",
18-
"start:backoffice": "./scripts/start.js"
18+
"start:backoffice": "./scripts/start.js",
19+
"deploy:docs": "./scripts/publish-site.js"
1920
},
2021
"dependencies": {
2122
"eslint-import-resolver-lerna": "^1.1.0",
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
---
2+
id: roadmap
3+
title: Roadmap
4+
---
5+
6+
This is not a promise of what is going to be implemented.
7+
This is just a simple overview of cool things that could come up one day.
8+
9+
Have suggestions of new features? [Open an issue](https://github.com/matheusmr13/create-micro-react-app/issues/new) and/or [contribute](https://github.com/matheusmr13/create-micro-react-app/blob/master/CONTRIBUTING.md)!
10+
11+
## Next steps
12+
13+
- Rename packages
14+
- Create "cmra" namespace
15+
- @cmra/cli -> "@cmra/cli"
16+
- react-microfrontend -> "@cmra/lib"
17+
- marketplace-frontend -> "@cmra/web"
18+
- marketplace-backend -> "@cmra/server"
19+
- export models from backend -> "@cmra/model"
20+
- Make it easy to deploy
21+
- server -> create package to extend -> `import Server from '@cmra/server'; Server.run();`
22+
- frontend -> create package to extend -> `import Webapp from '@cmra/web'; await Webapp.build(); Server.addStatic('build');`
23+
- docker image with all together
24+
- Permission
25+
- get things separate between users (currently works if you create your own environment)
26+
- Deploy
27+
- Schedule deploy to date
28+
- Recurrent deploy
29+
- Integrations to publish final package to:
30+
- Amazon s3
31+
- Package management integration, get packages from:
32+
- NPM
33+
- Amazon s3
34+
- Gitlab?
35+
- Extends command line
36+
- Application template (create-micro-react-app --from <APPLICATION_UUID>)
37+
- CLI for general uses such as preparing a next deploy
38+
- Flux between multiple namespaces
39+
- Define an order for each namespace (such as alpha->beta->main)
40+
- Expand namespaces
41+
- Create hidden "next deploy preview"
42+
- Integrate react-microfrontend with setting namespaces
43+
- Custom microfrontends
44+
- Set microfrontends meta infos (nav bar label? url? custom field)
45+
- Lazy loading
46+
- Changelog by version ()
47+
- Notifications
48+
- Changes to next deploy on namespace
49+
- Next deploy started (and done)
50+
- Integrations:
51+
- slack
52+
- email
53+
- Cannary deploy Vs Quality checks
54+
- Define some rules to get things checked and move to next deploy (really next to flux iniciative)

packages/doc/docs/backoffice/setup-application.md

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,20 @@ title: Setup application
55

66
Once we have a **Create Micro React App** backoffice up and running, access it and configure your application/microfrontends:
77

8-
- Click on "Applications" menu item
9-
- Click on "New" button
10-
- Fill up you application name and container's package name (eg: `webapp`)
11-
-
8+
- Click on "Applications" menu item;
9+
- Click on "New" button;
10+
- Fill up your application's name and container's package name (eg: `webapp`);
11+
- Once in your application's detail page, you should be able to setup your "integration type" and "destination";
12+
- Integration type: which infrastructure your application is going to be deployed at, eg: amazon s3, github pages, etc;
13+
- Destination: where your application should be deployed at. If you chose amazon s3 as your infrastructure, you should choose which bucket its going to be deployed at.
14+
- Setup your container microfrontend (click on "Edit" inside microfrontend's card):
15+
- Integration type: same as above, but point at where your release artifact is at;
16+
- Origin: where your artifacts are located at (if you are using amazon s3, this list will show folders inside AWS_ARTIFACTS_BUCKET environnement);
17+
- Click on "Save" and then on "Sync Versions" to fetch current released versions for your container.
18+
- You are good to go. Click on deploy and your destination should be updated (: (if you are curious about what happens when you click this button, check ["how it works" doc](https://matheusmr13.github.io/create-micro-react-app/docs/how-it-works))
19+
20+
These steps above got you up and running with a simple webapp without any microfrontends connected. Let's setup your first microfrontend?
21+
22+
- Go to your application's details page;
23+
- Fill up microfrontend info (very similar to above step where you setup webapp's container);
24+
- Go back to your application and deploy it!

0 commit comments

Comments
 (0)