Skip to content

Commit

Permalink
stackblitz providers updated
Browse files Browse the repository at this point in the history
  • Loading branch information
mehmetcetin01140 committed Dec 18, 2023
1 parent e4eeeb6 commit 1276507
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/app/showcase/layout/doc/codeeditor/templates.ts
Original file line number Diff line number Diff line change
Expand Up @@ -489,7 +489,8 @@ const getAngularApp = (props: Props = {}) => {
const serviceImports = code.service ? getServiceImports(code.service) : '';
const routerModule = code.routerModule ? code.routerModule : `RouterModule.forRoot([{ path: '', component: ${componentName} }])`;
const declarations = routeFiles && routeFiles.length ? (componentName ? routeFiles.map((r) => r.name).join(', ') + ',' + componentName : routeFiles.map((r) => r.name).join(', ')) : `${componentName}`;
const providers = ['MessageService', ...(code.service ? [code.service] : [])];
const providers = code.service && code.service.length ? code.service.map((s) => s).join(', ') : '';

const app_module_ts = `import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
Expand Down

0 comments on commit 1276507

Please sign in to comment.