Reputation: 937
I am trying to pass component to service file. I have an issue in my service file. The error said 'can not find name array'. please check attachment.
updateInvoiceHeaderStatus(fileNameFormArray:Array<any> ,orgName: string,fromDate: string,toDate: string){
return this.http.post(`${this.selectedfilenameurl}/${orgName}/${fromDate}/${toDate}`,fileNameFormArray)
}
Upvotes: 0
Views: 59
Reputation: 10464
This is a style issue, not a compilation issue. It works fine, but your style configuration just doesn't accept it.
Try using any[]
in place of Array<any>
Upvotes: 0
Reputation: 405
From angular 7 typescript 3.1 is introduced in core framework so you just need to check tslint.json
Upvotes: 1
Reputation: 2349
Are you using TSLint or Code Prettier extensions? because those are marking Array as an error due to not having a space bar after the ':' mark , anyways your code should run without a problem.
updateInvoiceHeaderStatus(fileNameFormArray: Array<any> ,orgName: string,fromDate: string,toDate: string){
return this.http.post(`${this.selectedfilenameurl}/${orgName}/${fromDate}/${toDate}`,fileNameFormArray)
Upvotes: 0