Questions tagged [lazy-loading]

1

votes
1

answer
1.7k

Views

How to React js event on scroll load other components

I have more components in one page. All pages loaded at the same time. But i want after scroll event loading next componentas. HomePage.js: render() { return ( ); } Have any idea? It is possible in react. Thank you!
Botir Ziyatov
-1

votes
0

answer
12

Views

How to fix “forChild of undefined”

I've implemented lazy loading on my Angular 4 app, which is localy working without problems, but on production I've got errors Cannot read property 'forChild' of undefined. The thing is I can not track the problem. If I'm going to deploy app 2 times error will occur on different routes each time. I...
HC1122
1

votes
2

answer
59

Views

Angular 4 Lazy Loading Child Components Not Loaded

I have a medium size Angular App. Which is taking quite a lot of time in loading. Thus I decided to use Lazy Loading. I have a FeedbackModule which is lazy loaded. It looks like this: Feedback Route: export const FEEDBACK_ROUTES: Routes = [ { path : '' , component : FeedbackComponent}, { path : 'pre...
Jayesh Choudhary
1

votes
1

answer
1k

Views

Lazy Loading Routes in React With Typescript AsyncComponent

I'm trying to lazy load routes in React by implementing the AsyncCompoment class as documented here Code Splitting in Create React App. Below is the es6 asyncComponent function from the tutorial: import React, { Component } from 'react'; export default function asyncComponent(importComponent) { clas...
Mike Lunn
0

votes
0

answer
4

Views

how to serialize entities that have a one to many relationship and a pagination in entity framework?

I have a two Model for two table having foreign key relationship. I have to get record from both table in single request. The structure of model is as follows:- EmployeeRecord.cs public partial class EmployeeRecord { [System.Diagnostics.CodeAnalysis.SuppressMessage('Microsoft.Usage', 'CA2214:DoNotCa...
Amardeep Gupta
1

votes
1

answer
72

Views

platformBrowserDynamic lazy loading different module

I have an application created in ionic which is much big in size and without lazy loaded pages. it contains over 30 pages and over 100 components. The problem is generated main.js is very big in size even after production build it is taking 5-6 seconds to load. Adding lazy loading to every page will...
Arkesh OrangeApp
1

votes
1

answer
275

Views

Eliminating Duplicate Queries with Eager Loading

I am trying to eliminate unnecessary queries on my site but am struggling to wrap my head around Eager Loading and Lazy Loading. All users on my site have listings, and listings have multiple users. They are connected through the table listing_users. Every listing then has one 'order' associated wit...
bdweix
1

votes
0

answer
105

Views

angularjs es6 lazy loading

I have angularjs application, built with webpack. I use ES6 modules, and import the css within each component. Anyway, I want the CSS to be included and used only when I navigate to the component - lazy loading. How can I do it?
user3712353
1

votes
1

answer
348

Views

Expanding a fancyTree via lazy load

I have set up my fancytree to open via lazy loading, and it works very nicely. $('#tree').fancytree({ selectMode: 1, quicksearch:true, minExpandLevel:2, autoScroll: true, source: [{ title: 'Root', key: '1', lazy: true, folder: true }], lazyLoad: function(event, data) { var node = data.node; data.res...
gordon613
1

votes
1

answer
339

Views

Translation not loaded on multimodule shared components - Angular 5

I have following problem. I created multimodule project with Angular 5 and would like to load translations dynamically for lazy loaded modules. Let's say my structure is like this: app ->app.module.ts ->shared-components ->shared.components.module.ts and components ->lazy-loaded-module1.ts ->lazy-l...
JFCorleone
1

votes
1

answer
447

Views

How to lazy load nodes when expanded in jsTree?

I have this js code to create a tree with the jsTree plugin. var n2 = { id : 'B', // will be autogenerated if omitted text : 'B', // node text icon : undefined, // string for custom state : { opened : false, // is the node open disabled : false, // is the node disa...
omega
1

votes
1

answer
556

Views

Spring Boot with 2 database configs - lazy loading with second config does not work

I have Spring Boot project with 2 database configs. Primary DB config: @Configuration @EnableTransactionManagement @EnableJpaRepositories(transactionManagerRef = 'primaryTransactionManager', entityManagerFactoryRef = 'primaryEntityManagerFactory', basePackages = { 'com.example.repository.primary' }...
Justas
1

votes
0

answer
52

Views

Pagination and LazyLoading in EFCore with Generic Repository Pattern

I am using EFCore and Generic Repository Pattern for my project and on my Core layer I have IEntityRepository interface: public interface IEntityRepository where T : class, IEntity, new() { PagedResult GetAll(int pageNumber, int pageSize, Expression filter = null, params Expression[] includeProperti...
Sümeyya Tuğçe Arar
1

votes
1

answer
1.1k

Views

Angular 4 Lazy Loading Not Loading Component

I'm working on an app that displays a form and a list of users. I'm trying to lazy load both of these modules via 2 buttons but the components do not load. I can see form.module.chunk.js and people.module.chunk.js in the network tab in my google developer tools, so the modules are being loaded. I do...
Jeremy Püringer
1

votes
0

answer
100

Views

Sticky Header with Loading Progress bar

I created a recyclerview using some Sticky header and Databean library.But I want to use Loading Progress bar for refresh the list.I have two Adapters first ItemViewBinder,second HeaderView Binder.And Databean is a list List items = result.getItems(); List headers = result.getHeaders(); List dataBe...
TsigumEnes
1

votes
0

answer
251

Views

EF 6 Error with NoTracking when navigating back and forth using the Proxy's Navigation Properties

In our EF 6 Code first application, we have issues with navigation properties in a non-tracking scenario. The requirements are: Entity must not be attached to the context and retrieved via NoTracking Proxy Generation must be enabled and Lazy Loading working You have to navigate to another Entity via...
Michael
1

votes
2

answer
628

Views

Changing default limit in Vaadin 8 lazy loading with grid

I have implemented lazy loading in Vaadin 8 with grid implementation. My backend runs on AWS Lambda which has a limit of 6 MB in response object. The lazy loading implementation gives default limit(40) to server which makes my program crash giving error as 'body too large'. I want to make changes in...
nikhil1265
1

votes
0

answer
42

Views

Jquery Lazy Loading not working properly in Production but working on UAT and local IIS

I am Using Jquery Lazy loading( version 1.X) and flex slider for image sliding. Everything is working fine in local IIS and UAT environment. After deploying in production image is not visible. I have attached screen shots ( for both production and UAT) here. Javascript: $('img.lazy').lazyload({ thr...
user9141780
1

votes
0

answer
101

Views

router reuse with lazy load causing error

I have referred this link to implement router reuse in my angular5 project that has lazyloading : Angular2 doesn't work Custom Reuse Strategy with Lazy module loading i.e. with data attribute having a custom key in the route. This works fine. However, when I log out from my site and go back to that...
Nat_centralogic
1

votes
3

answer
2.2k

Views

Angular 5 Update breaks lazy loading of modules

We have just upgraded our application from Angular 4 to Angular 5.2.6 The application was built with Angular CLI and CLI recently updated to 1.6.8. Our application uses lazy loading for some modules. This used to work perfectly with Angular 4, but we are now seeing some strange behaviour. The applic...
Kildareflare
1

votes
0

answer
219

Views

Empty rows in Vaadin grid after applying filter

I try to use Vaadin grid with lazy loading. When I add filter to the grid, at some filter values I see empty rows and get java.lang.IndexOutOfBoundsException: toIndex = 45. Below is my code: public class ProcessService { private List processList; private int i; public ProcessService() { processList...
Mariia
1

votes
0

answer
275

Views

Lazy loading modules with angular-router-loader errors with cannot find module “.”

Webpack has trouble finding a module that I am trying to lazy load with angular-router-loader. I am using the following: Webpack 2.2.1 Angular 5.2 angular-router-loader 0.8.2 Installed the angular-router-loader via npm, and added the loader to my webpack config:: { test: /\.ts$/, use: ['awesome-type...
Glen Au-Yeung
1

votes
1

answer
30

Views

Make Common Modules for Lazy loaded modules

What I need to know is that how can I define modules common Or we can say global for whole application that are used by all other children modules. Here If i use lazy loading , I have to write all the dependencies again to all my child modules . how can I avoid that and only define it in app.module....
Sameer
1

votes
1

answer
44

Views

Seperating page components from feature components in lazy-loaded module

Working on a large single-module Angular 5 application I'm trying to divide it into multiple modules to improve maintainability and performance (lazy loading). What I've done I've created multiple modules specifically to be lazy loaded. They contain The main component (page) that should render when...
Danyg
1

votes
0

answer
134

Views

spring repository EntityGraph JoinFormula Lazy loaded even when I don't want to

I have 3 Entities, Mouvement links Agent and Poste. I can't join directly poste and agent because it depends on the date of the movement. @NamedEntityGraph(name = 'graph.Agent.poste', attributeNodes = @NamedAttributeNode(value = 'poste')) @Entity @Table(name = 'agent') public class Agent extends Res...
ScorprocS
1

votes
0

answer
273

Views

Lazy loaded modules for Jasmine tests. Angularjs

I have some modules in my app to be lazy loaded. But they can't be used for jasmine tests. I cannot init/load module inside beforeEach or anywhere else. The problem is I can't find any information regarding this question. Is it possible to do it for my case. my karma config: config.set({ plugins: [...
Artem Ekzarho
1

votes
1

answer
34

Views

Fetch contacts and show simultaneously

I am fetching contacts and this work is going fine. But I am try to also show the contacts in bunch of 50 which is fetched, i.e. user don't have to wait until all contacts has been fetched. I try to with Asynctask , And Thread also but when I go to notify the list adapter then error has came. 'T...
Bhanu Sharma
1

votes
0

answer
210

Views

React lazy loading

I have an application in which I have an export feature. if the user clicks on the menu 'export', I will call a function in my export store and get the data and export it into a Excel file. I am using the library XLSX for exporting and I wanted to use code splitting to have lazy loading mechanism fo...
Afflatus
1

votes
0

answer
37

Views

Sending component as response to POST request

I have a ReactJS front-end with ExpressJS server, where I would like to implement component lazy loading. CURRENT BEHAVIOUR: After user clicks on the 'log in' button there is a fetch POST API called sending user credentials to the server which do the authentication and then responds with user profil...
TomasB
1

votes
0

answer
525

Views

Angular : Lazy load multiple Modules with the same route

I have an app where i want to lazy load two modules in the same moment with the same route path. My routing module would look like this : { path: 'mypath', loadChildren: () => HomeModule, canLoad: [HomeGuard] }, { path: 'mypath', loadChildren: () => AdvisorModule, canLoad: [AdvisorGuard] }, but this...
firasKoubaa
1

votes
0

answer
134

Views

jQuery.Lazy Vimeo Issues

I'm using jQuery.Lazy to make images load a little smoother on my website. It works like a charm on images, but I'm having some trouble with embedded Vimeo videos. I have the full packaged jquery.lazy.min.js uploaded and I call it using the following scripts: $('.lazy').lazy({ effect: 'fadeIn',...
Jacob Buller
1

votes
1

answer
399

Views

RouterModule.forRoot() called twice

I'm trying to implement lazyloading into my angular 5 app, but i get error: Uncaught (in promise): Error: RouterModule.forRoot() called twice. Lazy loaded modules should use RouterModule.forChild() instead. There my routing modules: app-routing.module.ts import { NgModule } from '@angular/core'; i...
1

votes
0

answer
23

Views

Lazy loading : Angular 1.6.x version using Webpack

We built angular application ,which has more module components. Because of more module components its taking time to load initially (its loading all components initially). Presently i have done code splitting using webpack(1.3.x version). It has 2 entry points , one is index.js which have all module...
aby km
1

votes
0

answer
69

Views

IntesectionObserver API fails to fire event upon horizontal scrolling on small screen

When laying elements horizontally (with horizontal scroll bar), and scrolling left/right, IntersectionObserver API does not always fire event when an observed element enters the viewport. This happens on mobile devices or when testing on desktop chrome while setting small dimensions of Responsive sc...
1

votes
1

answer
135

Views

LazyLoadingEnabled false not working

I am very confused, and I need help understanding lazy loading. I thought configuring lazy loading false would load an entire object including child elements, but that is not happening for me. Searching through other questions, I could not find an adequate answer. A server contains a list of superv...
MatthewHagemann
1

votes
0

answer
482

Views

Hibernate one-to-one lazy loading with Spring

There are a few similar answered questions from around 2013/2014 but the solutions do not seem to work for me, so I am hoping that something has perhaps changed since then and that I am not missing something glaringly obvious. (new project: spring-boot 2.0.2.RELEASE and hibernate 5.2.17.Final) The i...
Almadeus
1

votes
0

answer
135

Views

jQuery lazyload plugin with horizontal scroll for smartphone site

I am using jquery_lazyload plugin. When I use it with horizontal scroll div, it seem to stop working on simulating mobile devices of Chrome / Firefox DevTools and real smartphone(Android, iOS). Once I scroll to the position where I can't see the horizontal scroll div, the plugin starts working again...
mofmof
1

votes
1

answer
36

Views

How do I access/modify entities in a Database using Foreign Keys?

I am attempting to access Entities from a Database for ensuring Data Integrity while performing changes in my Database. I am testing different ways of altering the Foreign Key/Navigational Properties to point to different Rows in an associated Table. My Child class looks like this, public string Nam...
Tristan Trainer
1

votes
0

answer
272

Views

Angular shared module in lazyloaded module

my app has 2 major modules -- app module -- dashboard module //lazy loaded app module has container homeComponent which holds navbarComponent and heroComponent i want to import the navbarComponent into a child component of the dashboard module so i made the navbar as a shared module, exported the na...
1

votes
1

answer
282

Views

How to replace a low resolution background-image with a better one once the higher resolution image has loaded fully?

I want a very low quality of my background image to load with the initial paint, then a higher quality version to replace it, based on the browser's width. Here is my HTML : I'm giving the div a base64 background-image that's really low resolution. And in my CSS : @media(max-width: 600px) { div { b...
Brachamul

View additional questions