@gigster/module-loopback-base
v1.1.1
Published
Role | Name | Email | Slack ---- | ---- | ----- | ----- *Product Owner* | Ryan Borker | [[email protected]](mailto:[email protected]) | [@borker] *Maintainer* | Jerome Curlier | [[email protected]](mailto:[email protected]) | [@jerome]
Downloads
9
Readme
loopback_base
Role | Name | Email | Slack ---- | ---- | ----- | ----- Product Owner | Ryan Borker | [email protected] | [@borker] Maintainer | Jerome Curlier | [email protected] | [@jerome]
Overview
The Loopback base module modify the Loopback generated boilerplate to add code and configuration to ease further module development, to set the standard for the project and to productionize the Loopback project.
Usage
modules:
- name: loopback-base
location: >-
https://github.com/liquidlabs-co/gig-modules/tree/master/block/loopback-base
Endpoints
The modules generate the endpoind for the ping
:
Endpoint | Description
---- | -----
POST /ping | Provide {"started":"2017-12-15T22:25:31.416Z","uptime":12.795}
for the application to enable monitoring.
Generation
Boot
The following boot file is added to the Loopback application:
ping.js
Configuration
The following configuration file is added to the Loopback application:
component-config.production.json
Test
The following test files are added to the Loopback application:
test\e2e\explorer\index.spec.js
test\e2e\ping\index.spec.js
Troubleshooting
Tests
Module tests are defined using a test/scenarios.yaml
file. This file defines the set of example gigs that we generate as part of integration testing. To run all tests, run yarn test
at the root of this module.
Each scenario is generated in test/scenario/<name>
which you can then cd
into and run the actual app. For a scenario called default
, this is done via:
cd test/scenario/default
yarn install
# Run tests.
yarn test
# Start the app.
yarn start