lazy-loading

Lazy-loaded modules warnings after updating Angular from 8 to 9

我是研究僧i 提交于 2020-06-01 07:03:39
问题 After Angular update all lazy-loaded modules return warning: Error: [path/to/module/module-name.ts] is missing from the TypeScript compilation. Please make sure it is in your tsconfig via the 'files' or 'include' property. My function which returns modules array: export function manifests(prefix = '') { return [ { loadChildren: () => import(prefix + '/path/to/a.module').then(m => m.AModule), path: 'a', }, { loadChildren: () => import(prefix + '/path/to/b.module').then(m => m.BModule), path:

Lazy-loaded modules warnings after updating Angular from 8 to 9

大城市里の小女人 提交于 2020-06-01 07:01:09
问题 After Angular update all lazy-loaded modules return warning: Error: [path/to/module/module-name.ts] is missing from the TypeScript compilation. Please make sure it is in your tsconfig via the 'files' or 'include' property. My function which returns modules array: export function manifests(prefix = '') { return [ { loadChildren: () => import(prefix + '/path/to/a.module').then(m => m.AModule), path: 'a', }, { loadChildren: () => import(prefix + '/path/to/b.module').then(m => m.BModule), path:

Why loading attribute is not working in chrome?

て烟熏妆下的殇ゞ 提交于 2020-05-30 08:14:26
问题 I have replaced lazy loading with native chrome loading="lazy" attribute but it seems to be not working. I am using Chrome 76 latest version. I checked my page speed in https://developers.google.com/speed/pagespeed/insights and it still shows to Defer offscreen images! Not sure what exactly I have missed? <img class="img-fluid" loading="lazy" src="my-image-path" /> <img class="img-fluid" loading="lazy" src="my-image-path" /> <img class="img-fluid" loading="lazy" src="my-image-path" /> <img

Native lazy-loading (loading=lazy) not working even with flags enabled

≯℡__Kan透↙ 提交于 2020-05-29 04:31:42
问题 I am currently trying to update my Website using the new loading="lazy" attribute as shown here: https://web.dev/native-lazy-loading As seen in the video, everything works as expected, but compared with my waterfall diagram in chrome, it doesn't. How it looks: How it should look: This is how its implemented: <img class="has-border" src="https://andreramoncombucket.s3.amazonaws.com/static/assets/img/work/personal-website/pw_full.jpg" style="object-fit: cover;" alt="..." loading="lazy"> 回答1: I

Angular Material Datepicker | Lazy Loading + CustomDateAdapter + Internationalization - RangeError: Maximum call stack size exceeded

百般思念 提交于 2020-05-28 06:53:54
问题 Structure Question I'm not quite sure If I found the right place for this 2 code lines: providers: [ { provide: MAT_DATE_LOCALE, useValue: 'de-DE' }, { provide: DateAdapter, useClass: CustomDateAdapter, deps: [MAT_DATE_LOCALE, Platform] } ] Currently they are in my material.module => which is imported in shared.module => which is imported in app.module and every lazy loaded module. CustomDateAdapter: @Injectable() export class CustomDateAdapter extends NativeDateAdapter { subscription: any;

Angular Material Datepicker | Lazy Loading + CustomDateAdapter + Internationalization - RangeError: Maximum call stack size exceeded

╄→гoц情女王★ 提交于 2020-05-28 06:53:45
问题 Structure Question I'm not quite sure If I found the right place for this 2 code lines: providers: [ { provide: MAT_DATE_LOCALE, useValue: 'de-DE' }, { provide: DateAdapter, useClass: CustomDateAdapter, deps: [MAT_DATE_LOCALE, Platform] } ] Currently they are in my material.module => which is imported in shared.module => which is imported in app.module and every lazy loaded module. CustomDateAdapter: @Injectable() export class CustomDateAdapter extends NativeDateAdapter { subscription: any;

Should we disable lazy loading of Entity Framework in web apps?

房东的猫 提交于 2020-05-26 11:14:31
问题 I've heard that you have to disable the lazy loading feature of EF in web applications. (ASP.NET). Here and here, for instance. Now I'm really confused because I always thought that lazy loading should always be enabled. So now my question is: is it really a better idea to disable lazy loading in web apps in terms of performance. If yes, could anyone explain the reasons and mention the pros and cons? 回答1: Disabling lazy loading will prevent Select N+1 performance problems as well as recursive

Flutter ListView lazy loading in both directions (up, down)

北城以北 提交于 2020-05-15 21:50:29
问题 I would like to have a ListView in flutter which provides lazy loading in both directions (up, down). Example: There are 60000 items in the backend database which can be theoretically displayed. First I want to display the items 100..120 From these indices I want to be able to scroll up and down while lazy loading the new items Things to consider: The top and bottom edge (current index < 0 or > 60000) should be bouncing if reached while scrolling What I've tried: Most of the approaches in

Flutter ListView lazy loading in both directions (up, down)

旧时模样 提交于 2020-05-15 21:48:48
问题 I would like to have a ListView in flutter which provides lazy loading in both directions (up, down). Example: There are 60000 items in the backend database which can be theoretically displayed. First I want to display the items 100..120 From these indices I want to be able to scroll up and down while lazy loading the new items Things to consider: The top and bottom edge (current index < 0 or > 60000) should be bouncing if reached while scrolling What I've tried: Most of the approaches in

Lazy loading broken on prod build Angular 8

时光毁灭记忆、已成空白 提交于 2020-05-15 11:04:22
问题 I'm trying to get my lazy loaded routes to work in production. Currently, everything works fine in development mode but when I switch to AOT I get the error: TypeError: Cannot read property 'routeConfig' of undefined I've got this error reproduced in a tiny test project with a minimal amount of code. My lazy loaded modules look like this: const routes: Routes = [ { path: 'home', component: HomeComponent }, { path: 'lazy', loadChildren: () => import('./lazy-loaded-component/lazy-loaded.module'