I'm using a plug-in called lightSlider and I notice it doesn't display the whole content on first load until I refresh.

I have tried using

1. windows.load, 
2. ExecuteOrDelayUntilScriptLoaded,
3. setTimeout etc...

But still no luck.

Just need some tip or advice on how I could tackle this.

I was thinking of showing some preload image for a while before content to make sure the html if fully created


You should wrap your JQuery inside $(document).ready(function)({});

Additionally, if you're consuming data from SharePoint lists, you have to make sure the plug-in code doesn't run until after all of your SharePoint data is returned by using promises.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.