0.1.13 • Published 7 years ago

@cemizm/smartmirror-shared v0.1.13

Weekly downloads
1
License
MIT
Repository
github
Last release
7 years ago

Shared library of the smart mirror project

Contains all shared components, directives, pipes and services, used by the smart mirror project.

Installation

To install this library, run:

$ npm install @cemizm/smartmirror-shared --save

Documentation

A generated documentation of this project can be found here:

GitHub Pages

Usage

After the Installation of the library via npm, you can import it into your Angular/Ionic application by adding the SmartMirrorModule to the AppModule:

import {BrowserModule} from "@angular/platform-browser";
import {NgModule} from "@angular/core";
import {AppComponent} from "./app.component";
import {SmartMirrorModule} from "@cemizm/smartmirror-shared";

@NgModule({
  declarations: [
    AppComponent
  ],
  imports: [
    BrowserModule,
    SmartMirrorModule.forRoot({apiUrl: 'https://sm-webapi.azurewebsites.net/api'})
  ],
  providers: [],
  bootstrap: [AppComponent]
})
export class AppModule {
}

Once the shared library is imported, you can use its components, directives, pipes and services in your Angular application:

import {MirrorService} from "@cemizm/smartmirror-shared";

... 

  constructor(private mirrorService: MirrorService) {
  
  }

  getAll() {
    this.mirrorService.getAll().subscribe(mirrors => {
      this.mirrors = mirrors;
    }, err => {
      console.log(err);
    });
  }

License

MIT © Cem Basoglu

0.1.13

7 years ago

0.1.12

7 years ago

0.1.11

7 years ago

0.1.10

7 years ago

0.1.9

7 years ago

0.1.8

7 years ago

0.1.7

7 years ago

0.1.6

7 years ago

0.1.5

7 years ago

0.1.4

8 years ago

0.1.3

8 years ago

0.1.2

8 years ago

0.1.1

8 years ago

0.1.0

8 years ago