From 6b956fcd51cddd1a949ac92b5fb0eab59403822c Mon Sep 17 00:00:00 2001 From: Sander Elias Date: Fri, 20 Dec 2019 07:54:41 +0100 Subject: [PATCH] fix(ng-lib): correct httpclient import Instead of loading in the module in ng-lib get the httpclient dep closes #52 --- projects/scullyio/ng-lib/package.json | 2 +- .../scullyio/ng-lib/src/lib/components.module.ts | 12 +++++++++--- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/projects/scullyio/ng-lib/package.json b/projects/scullyio/ng-lib/package.json index 7b9cc203e..3d55bc82b 100644 --- a/projects/scullyio/ng-lib/package.json +++ b/projects/scullyio/ng-lib/package.json @@ -1,6 +1,6 @@ { "name": "@scullyio/ng-lib", - "version": "0.0.6", + "version": "0.0.7", "repository": { "type": "GIT", "url": "https://github.com/scullyio/scully/tree/master/projects/scullyio/ng-lib" diff --git a/projects/scullyio/ng-lib/src/lib/components.module.ts b/projects/scullyio/ng-lib/src/lib/components.module.ts index 1da589a7b..f1c6641bc 100644 --- a/projects/scullyio/ng-lib/src/lib/components.module.ts +++ b/projects/scullyio/ng-lib/src/lib/components.module.ts @@ -1,10 +1,16 @@ -import {HttpClientModule} from '@angular/common/http'; +import {HttpClient} from '@angular/common/http'; import {NgModule} from '@angular/core'; import {ScullyContentComponent} from './scully-content/scully-content.component'; @NgModule({ declarations: [ScullyContentComponent], - imports: [HttpClientModule], exports: [ScullyContentComponent], }) -export class ComponentsModule {} +export class ComponentsModule { + static forRoot() { + return { + NgModule: ComponentsModule, + deps: [HttpClient], + }; + } +}