1.0.8 • Published 5 years ago

@conweaver/devkit v1.0.8

Weekly downloads
1
License
MIT
Repository
-
Last release
5 years ago

CONWEAVER Schematics

This project contains schematics to get you started with custom components and functions for the CONWEAVER AppCreator. The intended users are CONWEAVER customers with a full installation.

Getting Started

Before you start, make sure that @angular/cli is installed globally. We currently use Angular 7.

npm install -g @angular/cli@7

Initialize a new Angular project with @angular/cli and cd into it. We suggest to use scss as default style extension and use routing to serve multiple pages. Throughout this example, the name MyProject is used, which can be substituted with any other name.

ng new MyProject --style=scss --routing
cd MyProject

All the following commands are executed in the MyProject folder.

Setup Library

Install this package to enable CONWEAVER schematics and create a library.

npm install @conweaver/devkit
ng generate @conweaver/devkit:cw-lib LibName

Add CwCore

You need CwCore in your project, please add the file conweaver-core.tgz in your application folder and install it. It is located in C:\ProgramData\Conweaver\AppCreatorPackages\Core.

npm install conweaver-core.tgz

Add Custom Component

ng generate @conweaver/devkit:cw-component ComponentName

Add Custom Function

ng generate @conweaver/devkit:cw-function AddOne

Test Your Components And Functions

Please modify the application (MyProject/src) to add demo pages for your custom components and functions. You may also use the e2e folder to add end-to-end tests for these demo pages.

Pack It

Use cwpm.exe to build and deploy your custom library. You need to point to your source directory (projects/my-project) and specify an output directory for the zip file.

cwpm.exe pack -d projects/my-project -o Packages

The result is MyProject.zip in the folder Packages.