Skip to content

quicksilverr/nx-loopback

Repository files navigation

nx-loopback

You can create a loopback 4 application within your nx workspace. This package has been made using nx-plugin executors and generators. It's more in a beta version, but improvements are more than welcome.

This workspace has been generated by Nx, a Smart, fast and extensible build system.

Install the package

With Yarn:

yarn add nx-loopback

With NPM:

npm i nx-loopback --save

Generate

Create a new application

nx g nx-loopback:app

This creates the loopback application, in the apps folder.

Argument Type Required Description
name string yes The name of the application
applicationClassName string no The application class name, being used in the controllers
description string yes The description about the application
applicationFeatures array of strings no Enable features in the applications, like docker,api,etc
directory string no A directory where the project is placed

Execute

Serve

nx run serve <app_name>

This starts the application.

Argument Type Required Description
nodeEnvironment string no The node environment LOCAL,STAGE,etc

Build

nx run build <app_name>

This builds the application using lb-stc command and creates a dist folder in the app.

Argument Type Required Description
nodeEnvironment string no The node environment LOCAL,STAGE,etc
clean boolean yes Clean the dist files, before build

Watch

nx run watch <app_name>

This starts the application, with watching file changes and reload. We use tsc-watch under the hood for this.

Argument Type Required Description
nodeEnvironment string no The node environment LOCAL,STAGE,etc

Clean

nx run clean <app_name>

This cleans the build files

Features yet to be added

  • Genreate controllers, repositories, models and datasources.
  • Migrate commands.
  • Docker deploy

Remote caching

Run npx nx connect-to-nx-cloud to enable remote caching and make CI faster.

Thanks to the NX folks, you can visit their docs

Visit the Nx Documentation to learn more.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published