This generator helps to create predefined frontend (web and mobile) applications compatible to an Aidbox app.
- Template for monorepo (shared files, common settings including linters, ci/cd and etc)
- Template for mobile (ios/android)
- Template for web
- A web application based on the create react app typescript template;
- A React Native mobile application (iOS/Android) with
react-native-navigation
; - A shared repository with default FHIR and Aidbox resources type declarations;
- Plugged in aidbox-react package;
- Shared ESLint and Prettier configuration files;
- react-test-renderer;
- CI/CD files (Docker, GitLab) including files to run tests using Aidbox;
- An inialized and configured Git repository.
(?) Two index.d.ts files?
frontend
└───chart
└───mobile (you can choose the name of this folder)
└───node_modules
└───shared
└───web
└───chart
│ other files
- Install a Yeoman globally:
npm install -g yo
- Run this generator:
npx yo beda
- Reply to questions:
-
What do you want to create:
Choose "Project". -
Path to monorepo git repository:
Hit "Enter" to use default template. If you want to use another template, provide a path to the git repository with another template. Can I provide a link to a local directory? -
Your mobile project name:
Provide a name for mobile app directory that will be added to the frontent directory, e.g. "mobile". Wait while generator is installing project files in the "frontend" directory.
- Go to the "frontend" directory:
cd ./frontend
- Run the project:
yarn start
-
(?) How can I start ony web or mobile app?
- Then open http://localhost:3000/ to see your web app.
-
(?) How can see a mobile app?
- Add a remote for the repository
git remote add origin <path_to_git_repository>
For development - clone the repo then try to run application generator:
git clone git@github.com:beda-software/frontend-beda-software-stack.git
cd ./frontend-beda-software-stack
npx yo ./generator-beda/generators/app
Set the current repo path as .
as answer for the following question:
? Path to monorepo git repository (https://github.com/beda-software/frontend-beda-software-stack.git)
https://github.com/beda-software/frontend-beda-software-stack/blob/master/generator-beda/README.md