The monorepo for all prePO applications.
This monorepo is based on Turborepo. It uses Yarn as a package manager. It includes the following packages/apps:
prepo-docs
: Our documentation that can be found on this url: docs.prepo.io.prepo-react-boilerplate
: Boilerplate NextJs based application that we use for every new project we start.config
:eslint
configurations (includeseslint-config-frontend
andeslint-config-server
)tsconfig
:tsconfig.json
s used throughout the monorepo (includestsconfig/frontend.js
,tsconfig/server.js
andtsconfig/base.js
)
Each package/app is 100% TypeScript.
This boilerplate contains a modern stack for building Web3 apps:
- Turborepo for running the monorepo structure
- TypeScript for static type checking
- ESLint for code linting
- Prettier for code formatting
- Node Version Manager to know which node version we are currently supporting
Clone the repository:
git clone https://github.com/prepo-io/prepo-monorepo
Install:
cd prepo-monorepo
yarn install
Move to the folder of the application you want to run and run it
cd apps/prepo-x-y
yarn dev
If you want to work on a specific application:
- You should move your terminal to that specific folder. Example:
cd apps/[frontend/smart-contracts]/[app-name]
- You should not do
yarn install
on the application folder. The only place to doyarn install
is on theroot
folder. After that, your application should work as expected. Yarn workspaces will handle the instalation of your packages corresponding to your applicationpackage.json
. If there's any package version that is re-used across other applications, that will also be handled automatically.
Which one is the name of my application on yarn workspaces?
To get that the name of your application, you just need to open the package.json
file inside your application folder and that would be the name
property written there.
Locate the name of your application in yarn workspaces.
Then you can run the command:
yarn workspace [yarn-workspace-application-name] add react
Don't forget to remove the caret after installing to lock the version and re-run yarn install
on the root folder.
Locate the name of your application in yarn workspaces.
Then you can run the command:
yarn workspace [yarn-workspace-application-name] add @types/react -D
Don't forget to remove the caret after installing to lock the version and re-run yarn install
on the root folder.
How do I install a dependency/dev dependency on the root package.json that will be shared across other apps?
Go to the root folder of this monorepo.
Then you can run the command:
yarn add dependency-name -W
Include -D
if you are planning to install a dev dependency.
Don't forget to remove the caret after installing to lock the version and re-run yarn install
on the root folder.
The AGPL V3 license only applies to the code within the repository. Any assets or other files (in part or whole) that already have a non-open-source license are excluded.