Skip to content

Conversation

@kishoreweblabs
Copy link

Added 2 New callback function 'beforeSend' and 'afterContentLoad' and new option reTriggerUntil option
added two public function 'getdata' and 'getOptions' , and
load request is changed to ajax get method for better content manupulation.

beforeSend- is called before sending the ajax request. Useful for changing the 'nextHref' or append some parameter to 'nextHref'
afterContentLoad- is called after data is received, but data is not appended to the scrolling div. Useful for data manipulation or formatting the received data.
reTriggerUntil - it will restart the scrolling when next button is clicked on

getdata and getOptions public let you access the jscroll data and option.

Removed animate and load function for better data handing and animation
$e.animate({scrollTop: $inner.outerHeight()}, 0, function() {})
animate don't let us to run our custom animation code. Better approach is to use it in 'Callback' function

$inner.find('div.jscroll-added').last().load(data.nextHref, function(r, status) {});
.load is replaced with
$.get(data.nextHref, function(r, status) {});

for better content handing

Thanks
Kishore
Kishoreweblabs.com

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant