stackblitz / stackblitz/starters
New Angular starter is not beginner friendly
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 151
- Forks
- 96
- Avg merge
- 9d 6h
- Merged PRs (30d)
- 2
Description
The new Angular starter seems to have removed the default AppComponent that all new Angular projects, generated by Angular CLI, are setup with. There's no app folder, instead the usual contents of the AppComponent are now somehow in main.ts -
import 'zone.js/dist/zone';
import { Component } from '@angular/core';
import { CommonModule } from '@angular/common';
import { bootstrapApplication } from '@angular/platform-browser';
import { FirstComponent } from './first/first.component';
@Component({
selector: 'my-app',
standalone: true,
imports: [CommonModule, FirstComponent], // ERROR - cannot import custom components
template: `
<h1>Hello from {{name}}!</h1>
<a target="_blank" href="https://angular.io/start">
Learn more about Angular
</a>
<app-first></app-first>
`,
})
export class App {
name = 'Angular';
}
bootstrapApplication(App);
Creating new, custom components and importing them into an AppComponent (which is what everyone does when getting started with Angular) now no longer works -
URL - https://stackblitz.com/edit/stackblitz-starters-2hwyyr?file=src%2Fmain.ts
It is not convenient having users go and first learn how to deal with standalone components and NgModule, if all they want to do is get started with a simple Angular app quickly.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by opening the linked starter and inspecting src/main.ts, then compare its structure with a new Angular CLI project. Reproduce the custom-component import error shown in the issue. Done means the starter offers the expected beginner-friendly AppComponent structure and a newly created component can be imported and rendered successfully.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- angular, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100