Skip to content

Commit

Permalink
fixes #4 - remove BrowserAnimationModule import from component-module
Browse files Browse the repository at this point in the history
  • Loading branch information
Tom Müller committed Apr 16, 2019
1 parent 6f9fc98 commit d73c648
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 5 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,9 @@ import { NgMatSearchBarModule } from 'ng-mat-search-bar';
})
```

and you also need to add Material Icons webfont by adding
Also make sure that in your _app.module.ts_ you import the `BrowserAnimationsModule`, otherwise the animations will not work!

You also need to add Material Icons webfont by adding

```html
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ng-mat-search-bar",
"version": "3.0.1",
"version": "3.1.0",
"license": "MIT",
"scripts": {
"build": "ng build",
Expand Down
8 changes: 7 additions & 1 deletion src/app/app.module.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { NgModule } from '@angular/core';
import { FormsModule } from '@angular/forms';
import { BrowserModule } from '@angular/platform-browser';
Expand All @@ -7,7 +8,12 @@ import { NgMatSearchBarModule } from './ng-mat-search-bar/ng-mat-search-bar.modu

@NgModule({
declarations: [AppComponent],
imports: [BrowserModule, FormsModule, NgMatSearchBarModule],
imports: [
BrowserModule,
BrowserAnimationsModule,
FormsModule,
NgMatSearchBarModule
],
providers: [],
bootstrap: [AppComponent]
})
Expand Down
2 changes: 0 additions & 2 deletions src/app/ng-mat-search-bar/ng-mat-search-bar.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,11 @@ import {
MatInputModule,
MatRippleModule
} from '@angular/material';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';

import { MatSearchBarComponent } from './mat-search-bar/mat-search-bar.component';

@NgModule({
imports: [
BrowserAnimationsModule,
CommonModule,
FormsModule,
MatIconModule,
Expand Down

0 comments on commit d73c648

Please sign in to comment.