Closed tomylee001001 closed 8 years ago
import it from @angular/core like so:
import {provide} from "@angular/core"
provide(TNSFontIconService, {
useFactory: () => {
return new TNSFontIconService({
'icon': 'css/ionicons-android.css'
}, true)
}
})
thanks.
How does this plugin now work with the final release of angular 2? where provide
is not found in @angular/core
anymore?
@dondragon2 Add it to your providers
in your ngModule
like so:
providers: [
{ provide: TNSFontIconService, useFactory: () => {
return new TNSFontIconService({
'icon': 'css/ionicons-android.css'
}, true)
} }
]
https://angular.io/docs/ts/latest/guide/dependency-injection.html#!#factory-provider
Hi ,
I did every step you mention to implement this plugin in my app but i can find the provide module you use in the nativeScriptBootstrap.