javascript - Masonry plugin returning error when used with Infinite Scroll in tumblr -


I know that a lot has been written about it, but I think I am close to solving this issue I am

I am trying to use a theme on which Masonry is installed, but now the customer is asking for eternal scroll and I am having problems with it.

In the beginning I was seeing errors in the console for both the masonry and infinite scroll plugin, at least I'm only seeing the masonry error. And it seems that the Infinite Scroll function is calling pages after the post, it's just that Masonry is struggling to add them to the page in the right layout.

I think it has something to do with my callback function, but I'm worried that I may also have the ability to load images (this plugin is also called through theme).

I have a copy of the current topic:

Inline script looks like this:

  var $ wall = $ ('# posts' ); $ (Window) .load (function) (// grid $ wall messary ({column wide: 84, items selected: '. Post: view'}); // infinite scroll $ ('# post'). Infinitiuscroll ({NavSelector: "// Selector for paging navigation, next hidden (this will be hidden) selector:" Paginated: first ", // selector (page 2) item selector for next link:" #posts .post "// you will retrieve the selector for all items}, // to masonry as callback function. (New elements); $ wall.masonry ('added', $ new almes);});  

Markup is a simple one like this The block follows:

  
& lt ; / Div>

Error:

  Unkit type error: undefined function masonry. Js is not: 10  

()

Well I have some work code on it. Sounds like:

  (function () {var $ tumblelog = $ ('# posts'); $ Tumblelog.infinitescroll ({navSelector: "Paginated", Next Selector: "Endorsement: Last-Child", Item Chooser: "Article",}, Function (New Elements) {var $ newElems = $ (newElements) .css ({opacity: 0}); $ newElems.images loaded (function () {$ newElems.animate ({opacity: 1}); $ tumblelog.masonry ('append', $ newElems);})}}; $ Tumblelog.images Loaded (function () {$ tumblelog.masonry ({columnWidth: 84});});}) ();  

Picture loaded script was required (because this question has also been raised by me).


Comments

Popular posts from this blog

winforms - C# Form - Property Change -

javascript - amcharts makechart not working -

java - Algorithm negotiation fail SSH in Jenkins -