CRUMS Lib
Developing
Install
npm install
Make a local link (included in 'start' script)
ng build
cd dist/crums
npm link
Watch
npm start
On external project
Link to local package
npm link @camdh/crums
External project config
Edit tsconfig.json
{
"compilerOptions": {
"paths": {
"@camdh/crums": ["node_modules/@camdh/crums"],
"@camdh/crums/*": ["node_modules/@camdh/crums/*"]
Edit angular.json
{
"projects": {
"app": {
"architect": {
"build": {
"options": {
"preserveSymlinks": true,
"assets": [
{
"glob": "**/*",
"input": "node_modules/@camdh/crums/assets",
"output": "assets"
}
Edit global.scss
@import "~@camdh/crums/assets/styles/global"
Edit app.module.ts
@NgModule({
declarations: [AppComponent],
entryComponents: [],
imports: [
BrowserAnimationsModule,
BrowserModule,
AppRoutingModule,
IonicModule.forRoot(),
QuillModule.forRoot(),
CrumsModule.forRoot({
name: 'project',
apiUrl: 'https://apps.camdh.com:443/project',
custom: { login: LoginPage },
}),
Production
If linked, unlink
npm unlink @camdh/crums
Install dependency
npm install @camdh/crums@latest