View my.service.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Injectable } from '@angular/core'; | |
import { HttpClient } from '@angular/common/http'; | |
@Injectable() | |
export class MyService { | |
constructor(private http: HttpClient) { } | |
… | |
} |
View my.module.tns.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { NativeScriptHttpClientModule } from 'nativescript-angular/http-client'; | |
@NgModule({ | |
imports: [ | |
NativeScriptHttpClientModule, | |
… | |
] | |
… | |
}) | |
export class MyModule { } |
View my.module.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { HttpClientModule } from '@angular/common/http'; | |
@NgModule({ | |
imports: [ | |
HttpClientModule, | |
… | |
] | |
… | |
}) | |
export class MyModule { } |
View component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Component({ | |
selector: 'app-name', | |
templateUrl: './name.component.html', | |
styleUrls: ['./name.component.css'], | |
}) |
View tsconfig.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
"exclude": [ | |
"**/*.ns.ts", | |
"**/*.tns.ts", | |
"**/*.android.ts", | |
"**/*.ios.ts" | |
] |