Skip to content

Commit

Permalink
(fix): Fix module bundle
Browse files Browse the repository at this point in the history
  • Loading branch information
meeroslav committed Nov 27, 2017
1 parent 79df510 commit 1574940
Show file tree
Hide file tree
Showing 6 changed files with 40 additions and 37 deletions.
13 changes: 8 additions & 5 deletions .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,11 @@ tests
coverage
config
karma.conf.js
copy.js
tsconfig.json
tslint.json
webpack.config.js
package-lock.json
!*.metadata.json
*.ngfactory.ts
*.ngsummary.json
!bundles/*.js
CODE_OF_CONDUCT.md
.*

############
Expand All @@ -43,3 +40,9 @@ Desktop.ini

# Mac crap
.DS_Store

############
## Demos
############

demo/*
13 changes: 1 addition & 12 deletions index.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,3 @@
export * from './src/typeahead.module';
export * from './src/typeahead.component';
export * from './src/typeahead.interface';

import { TypeaheadComponent } from './src/typeahead.component';
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';

@NgModule({
imports: [CommonModule],
declarations: [TypeaheadComponent],
exports: [TypeaheadComponent]
})
export class TypeaheadModule {
}
27 changes: 13 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ngx-type-ahead",
"version": "1.0.1",
"version": "1.0.2",
"description": "Typeahead multi-select dropdown component for angular",
"scripts": {
"test": "karma start",
Expand Down Expand Up @@ -35,22 +35,21 @@
"rxjs": ">=5.0.0"
},
"devDependencies": {
"@angular/animations": "4.3.3",
"@angular/common": "4.3.3",
"@angular/compiler": "4.3.3",
"@angular/compiler-cli": "4.3.3",
"@angular/core": "4.3.3",
"@angular/forms": "4.3.3",
"@angular/http": "4.3.3",
"@angular/platform-browser": "4.3.3",
"@angular/platform-browser-dynamic": "4.3.3",
"@angular/platform-server": "4.3.3",
"@angular/router": "4.3.3",
"@angular/animations": "~4.3.3",
"@angular/common": "~4.3.3",
"@angular/compiler": "~4.3.3",
"@angular/compiler-cli": "~4.3.3",
"@angular/core": "~4.3.3",
"@angular/forms": "~4.3.3",
"@angular/http": "~4.3.3",
"@angular/platform-browser": "~4.3.3",
"@angular/platform-browser-dynamic": "~4.3.3",
"@angular/platform-server": "~4.3.3",
"@angular/router": "~4.3.3",
"@types/hammerjs": "2.0.34",
"@types/jasmine": "2.5.47",
"@types/node": "7.0.22",
"awesome-typescript-loader": "3.1.3",
"bootstrap": "^3.3.7",
"clean-webpack-plugin": "^0.1.16",
"codelyzer": "~4.0.1",
"concurrently": "3.1.0",
Expand All @@ -71,7 +70,7 @@
"rxjs": "~5.4.0",
"source-map-loader": "0.2.1",
"ts-helpers": "1.1.2",
"tslint": "~5.8.0",
"tslint": "5.8.0",
"tslint-eslint-rules": "~4.1.1",
"tslint-loader": "3.5.3",
"typescript": "~2.3.3",
Expand Down
4 changes: 2 additions & 2 deletions src/typeahead.component.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import {
Component, forwardRef, Input, OnDestroy, ElementRef, Output, OnChanges,
EventEmitter, AfterViewInit, Inject, OnInit, Renderer2, HostListener, HostBinding
EventEmitter, AfterViewInit, Inject, OnInit, Renderer2, HostListener, HostBinding, SimpleChanges
} from '@angular/core';
import { Observable } from 'rxjs/Observable';
import { Subscription } from 'rxjs/Subscription';
Expand Down Expand Up @@ -230,7 +230,7 @@ export class TypeaheadComponent implements ControlValueAccessor, AfterViewInit,
this._inputChangeEvent.emit('');
}

ngOnChanges(changes) {
ngOnChanges(changes: SimpleChanges) {
if (changes.suggestions && !changes.suggestions.firstChange) {
this.allMatchesSubscription.unsubscribe();
this.matchesSubscription.unsubscribe();
Expand Down
11 changes: 11 additions & 0 deletions src/typeahead.module.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import { TypeaheadComponent } from './typeahead.component';
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';

@NgModule({
imports: [CommonModule],
declarations: [TypeaheadComponent],
exports: [TypeaheadComponent]
})
export class TypeaheadModule {
}
9 changes: 5 additions & 4 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"compileOnSave": false,
"compilerOptions": {
"noImplicitAny": true,
"module": "commonjs",
"declaration": true,
"moduleResolution": "node",
"target": "es5",
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"target": "es5",
"declaration": true,
"moduleResolution": "node",
"noUnusedLocals": true,
"types": [
"hammerjs",
Expand All @@ -17,6 +17,7 @@
},
"files": [
"index.ts",
"./src/typeahead.module.ts",
"./src/typeahead.component.ts",
"./src/typeahead.interface.ts",
"./tests/typeahead.component.spec.ts"
Expand Down

0 comments on commit 1574940

Please sign in to comment.