Questions tagged [angular-lazyloading]

83 questions
0
votes
1 answer

Angular: reactive module import does not find `formGroup` directive

I have already taken a look at this question which had a lot of answers (all the same) but it could not fix my problem. Let me quickly lay out my project structure @NgModule({ declarations: [AppComponent], imports: [AppRoutingModule,…
0
votes
0 answers

Angular 13 Lazy Chunk Files are not loading for some users

Our Angular 13 app build looks like this Initial Chunk Files | Names | Raw Size | Estimated Transfer Size main.e9020ce07f592565.js | main | 4.64 MB | …
Mher
  • 985
  • 9
  • 23
0
votes
0 answers

How to get page when I refresh angular route in browser

I have this router setup in my angular app (non-essential parts cut out for brevity): #AppRoutingModule const routes: Routes = [ { path: '', redirectTo: 'apprent', pathMatch: 'full' }, { path: 'apprent', loadChildren: () =>…
shuffler
  • 66
  • 5
0
votes
1 answer

Angular lazy loading external styles and scripts on specific component causes layout glitch for brief second

as I already described in the title, I have some styles and script that I only want to load on one specific component but this causes a glitch in the view, looks like the page is displayed before the css is loaded. Is there a way to adjust this code…
Daniel
  • 11
  • 3
0
votes
1 answer

Angular Lazy Loaded Component Re-renders on navigation

Our application is setup so users navigating to a certain set of routes are lazy loaded like below: { path: path1, component: Cmp1, loadChildren: () => LazyLoadedModule, } We use a router link to navigate to one of these lazy loaded…
trebek1
  • 755
  • 1
  • 8
  • 28
0
votes
1 answer

How to lazy load Angular Components of the home page?

I have my code as given below in app.component.html i.e. as soon as the user lands on the home screen; I want to lazy load the app-image-gallery & app-users-list and want to load them with some Shimmer effect or Loader as soon as the user reaches…
0
votes
1 answer

runtime compiler is not loaded angular 8 when lazy loading modules are accessed over browser

I have an angular application where i use lazy loading for one of its module named 'security', i mentioned in routes array of app.routing.module.ts const routes: Routes = [ {path:'path1',component:Path1Component}, …
Lisa
  • 655
  • 3
  • 10
  • 34
0
votes
1 answer

use browser animations module in my library

I have to used browser animations module in my angular library because of my date picker and I am using lazy loading so I got several modules in my project when I want import my library in my modules I get this common error "Lazy Loading…
0
votes
1 answer

Angular 11: Components and Directives not regognized inside Lazy Loaded Module

I want to split my angular project to load Website part in main module and application part in lazy loaded module. While everything worked before, now I am getting plenty of errors about compoentns and directives not known: Component from same…
0
votes
1 answer

Angular 11 - Lazy load routing issue

Trying to create CRUD opration with MEAN stack. Currently using Angular 11 cli, I've created lazy module. the lazy module has add/edit/list components. To list the data, I'm using Angular materials. The problem what here I'm facing is that am not…
Mr. Learner
  • 978
  • 2
  • 18
  • 48
0
votes
0 answers

angular lazyload pages with same start path

I have a pretty big project and in order to reduce bundle size i decided to divide it into multiple modules with lazy load. and here is my app-routing const routes: Routes = [ { path: 'profile', loadChildren: () =>…
Behnam Aminazad
  • 411
  • 2
  • 5
  • 19
0
votes
1 answer

How many instances of a module end up in the final bundle if it's referenced by several modules?

I'm wondering what's the best strategy between a shared module that contains all the reusable code individual reusable codes that are referenced when needed I suppose that the case against putting all the reusable codes in a shared module is that…
Richard77
  • 20,343
  • 46
  • 150
  • 252
0
votes
1 answer

Angular cross-domain dynamic component loader

I am investigating Micro-Frontend possibilities with Angular. I am looking into the feasibility of having independently the different parts of the UI served by their own HTTP server process but composed dynamically on the main UI; which is merely a…
0
votes
1 answer

How to load Module from another Angular Project?

I just play around with Angular and Spring Clound Microservices. I have a Main Angular Project with a Menu, I do a request to my Gateway and receive a List of all available Microservices currently online. Based on this List my Menu is dynamicly…
0
votes
1 answer

Implement Angular Lazy Loading inside one Module with different components

I'm trying to implement lazy loading in my test application. I have one home/main/app module with an example name - Movies. I've created a new module called Auth with two components - Registration and Login. I want both components to be lazily…