Hello I have a problem with my js code.
addScrollListener = (id, totalSize) => {
// logger.debug(id+' scroll on bottom');
// logger.debug('totalSize: ' + totalSize);
let lastScrollTop;
let fn = window['fn_' + id];
$('#' + id).scroll(function(e) {
let elemsSize = $(this).find('.v-csslayout').length; //
// logger.debug('filter scrolled');
let scrollTop = $(this).scrollTop(),
innerHeight = $(this).innerHeight(),
scroll_height = $(this)[0].scrollHeight;
// fn('scrollTop: '+scrollTop+', innerHeight:'+innerHeight+', scroll_height: '+scroll_height);
if (scrollTop + innerHeight >= scroll_height && lastScrollTop != scrollTop) {
fn(true);
lastScrollTop = scrollTop;
}
});
}
id parameter has a error “Parsing Errror: Assigning to rvalue”