_ _
__ ___ __ __ _ _ __ _ __ (_) __| |
\ \ /\ / / '__/ _` | '_ \| '_ \| |/ _` |
\ V V /| | | (_| | |_) | |_) | | (_| |
\_/\_/ |_| \__,_| .__/| .__/|_|\__,_|
|_| |_|
This is a template documentation, @wrappid/toolkit uses this template to create backend service boilerplate.
Table of Contents
Wrappid
Service Boilerplate
This is a service middleware boilerplate application to support frontend applications built using the wrappid
framework, which enables simultaneous development of web and mobile application.
This getting started section will help you setup a basicservic middleware built using the Wrappid
framework for Frontend Wrappid Projects. Follow the below steps to get going.
2.1 What are my Pre-requisites?
2.2. How to Create?
2.3. How to Setup?
2.4. How to Start?
- Refer here
- install @wrappid/toolkit globally. Click herefor installation guide of @wrappid/toolkit.
It is expected that you have successfully installed @wrappid/toolkit(wrappid framework's CLI tool) and initialised it. Run the below command to create Frontend Wrappid Project
wrappid init service <wrappid>
Note: If you want to setup a wrappid-service project that is already in your github, you need to clone it. After clonning, run
npm i
at the root of the project
Run the below command to setup a Backend Wrappid Project.
cd <wrappid>-<service>
wrappid setup
Note: Unlike wrappid frontend biolerplate(wrappid-app), there are no runtime environments for wrappid-service
Run the below command to start the development backend service:
cd wrappid-service
wrappid start
This should start your backend service middlewear at localhost:8080
Wrappid Service can be runned in 3 environments:
- Dev: Suitable for Development
- Stage: Suitable for Testing
- Prod: Suitable for Production
By default, Wrappid Servoce project setups and starts in dev
environment.
These environments are to be configured in wrappid.conf.json located at the root of wrappid-app
project
To run a Wrappid Servoce project in a different environment, run the below command:
cd wrappid-service
wrappid start --env=[dev|stage|prod]
Used for controllers
Used for functions
Used for Middlewears functions
Used to get models
Used to get tasks
Used for validation
As of now 1 npm package is used by wrappid-service
, i.e,
3.1. @wrappid/service-core