Skip to main content

app.component.ts

import { Component } from '@angular/core'; import { AppComponent } from './app.component';

@Component({ selector: 'app-root', templateUrl: 'app.component.html' }) export class AppComponent { title = 'frontend'; }

app.modules.ts

import { BrowserModule } from '@angular/platform-browser'; import { NgModule } from '@angular/core';

import { AppRoutingModule } from './app-routing.module'; import { AppComponent } from './app.component';app.component.ts

@NgModule({ declarations: [ AppComponent, ], imports: [ BrowserModule, AppRoutingModule ], providers: [], bootstrap: [AppRoutingModule]

import { Component } from '@angular/core';
import { AppComponent } from './app.component';

@Component({
  selector: 'app-root',
  templateUrl: 'app.component.html' 
})
export class AppComponent {
  title = 'frontend';
}

  

})app.modules.ts

export class AppModule { }

import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';

import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component';

 @NgModule({
     declarations: [
         AppComponent,
     ],
     imports: [
         BrowserModule,
         AppRoutingModule
     ],
     providers: [],
     bootstrap: [AppRoutingModule]

 })

export class AppModule { }

app.component.ts

import { Component } from '@angular/core'; import { AppComponent } from './app.component';

@Component({ selector: 'app-root', templateUrl: 'app.component.html' }) export class AppComponent { title = 'frontend'; }

app.modules.ts

import { BrowserModule } from '@angular/platform-browser'; import { NgModule } from '@angular/core';

import { AppRoutingModule } from './app-routing.module'; import { AppComponent } from './app.component';

@NgModule({ declarations: [ AppComponent, ], imports: [ BrowserModule, AppRoutingModule ], providers: [], bootstrap: [AppRoutingModule]

})

export class AppModule { }

app.component.ts

import { Component } from '@angular/core';
import { AppComponent } from './app.component';

@Component({
  selector: 'app-root',
  templateUrl: 'app.component.html' 
})
export class AppComponent {
  title = 'frontend';
}

  

app.modules.ts

import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';

import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component';

 @NgModule({
     declarations: [
         AppComponent,
     ],
     imports: [
         BrowserModule,
         AppRoutingModule
     ],
     providers: [],
     bootstrap: [AppRoutingModule]

 })

export class AppModule { }
Fonte Link

Angular, erro no AppComponent e no AppModule, não está importando

app.component.ts

import { Component } from '@angular/core'; import { AppComponent } from './app.component';

@Component({ selector: 'app-root', templateUrl: 'app.component.html' }) export class AppComponent { title = 'frontend'; }

app.modules.ts

import { BrowserModule } from '@angular/platform-browser'; import { NgModule } from '@angular/core';

import { AppRoutingModule } from './app-routing.module'; import { AppComponent } from './app.component';

@NgModule({ declarations: [ AppComponent, ], imports: [ BrowserModule, AppRoutingModule ], providers: [], bootstrap: [AppRoutingModule]

})

export class AppModule { }