question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add `--standalone` option to `ng new`

See original GitHub issue

Command

new

Description

Right now ng new do not use standalone application bootstrap, but usual app instead. Nw option should change application to the standalone option, without AppModule

Describe the solution you’d like

No response

Describe alternatives you’ve considered

No response

Issue Analytics

  • State:open
  • Created a year ago
  • Reactions:16
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

5reactions
alan-agius4commented, Oct 12, 2022

@mounilKshah, thanks for offering to take this up. The new project structure is still in its design phase.

0reactions
arturobercommented, Dec 20, 2022

When creating an app with this option. Will the CLI generate standalone components/directives in the project by default? (not needing --standalone flag). What about generating functional guards/interceptors/resolvers by default?

Like @LMFinney said. Is there any information regarding when / how will this be implemented? . I’ve been using (and teaching) these last 2 months Angular 15 with standalone components and functional guards/interceptors/resolvers, and I find it simpler and cleaner. Sadly there are many libraries (including Universal) that still don’t support apps without AppModule (using bootstrapApplication) and fail when executing ng add (Bootstrap module not found).

Read more comments on GitHub >

github_iconTop Results From Across the Web

Getting started with standalone components - Angular
You can use standalone components with existing NgModule -based libraries or dependencies in your template. Standalone components can take full advantage of the ......
Read more >
Angular Standalone Components: Welcome to a World ...
The term “standalone” refers to components, directives, or pipes that can be used independently of NgModule . Although you'll still need to use...
Read more >
Angular 14—Introducing Standalone Components - Telerik
You can create a standalone component, pipe or directive by using the --standalone flag in the ng generate component command: ng g p...
Read more >
Getting started with Standalone Components - Google Codelabs
1. Introduction · 2. Environment setup · 3. Create a new application · 4. Display the photos · 5. Add a new standalone...
Read more >
A guide to Standalone Components in Angular - Ninja Squad
The Angular CLI team added a new flag --standalone to ng generate ... A standalone component is declared in the imports option of...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found