Browse Source

refactor : migrate schematics template to inject() DI

pull/23262/head
Fahri Gedik 9 months ago
parent
commit
8a1ef937bb
  1. 5
      npm/ng-packs/packages/schematics/src/commands/api/files-service/proxy/__namespace@dir__/__name@kebab__.service.ts.template

5
npm/ng-packs/packages/schematics/src/commands/api/files-service/proxy/__namespace@dir__/__name@kebab__.service.ts.template

@ -5,6 +5,7 @@
providedIn: 'root',
})
export class <%= name %>Service {
private restService = inject(RestService);
apiName = '<%= apiName %>';<%
for (let {body, signature} of methods) { %>
<%
@ -26,6 +27,4 @@ export class <%= name %>Service {
body: <%= body.body %>,<% } %>
},
{ apiName: this.apiName,...config });<% } %>
constructor(private restService: RestService) {}
}
}
Loading…
Cancel
Save