These are chat archives for angular/material

23rd
Jan 2017
aminsmartsense
@aminsmartsense
Jan 23 2017 05:52
Hello I am used ngDatepicker.. that datepicker I have put in modal(pop up). when I am closed modal that time I want to date value clear. anyone help me please?
ujjwal solanki
@geeky77_twitter
Jan 23 2017 11:09

i am getting this error : Can't resolve all parameters for SharedService: (?).

SharedService.ts
import {Injectable} from '@angular/core';
import {Http, Response} from '@angular/http';
import 'rxjs/add/operator/map';
@Injectable()
export class SharedService{
constructor(public http: Http){}
getInfo(){
return this.http.get('https://api.github.com').map(
(res: Response) => res.json());
}
}

app.module.ts;

import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { HttpModule } from '@angular/http';
import {SharedService} from "../shared/shared.service";
@NgModule({
imports: [ BrowserModule,, AppRoutingModule, HttpModule ],
declarations: [ AppComponent, AboutComponent],
providers: [SharedService],
bootstrap: [ AppComponent ]
})