Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trigger 'alnp-post-loaded' have pframeter as array #183

Open
TooLogic opened this issue Nov 9, 2023 · 0 comments
Open

Trigger 'alnp-post-loaded' have pframeter as array #183

TooLogic opened this issue Nov 9, 2023 · 0 comments

Comments

@TooLogic
Copy link

TooLogic commented Nov 9, 2023

Describe the bug

View source code auto-load-next-post.(dev).js
row 417
var triggerParams = [ post_title.text(), post_url, post_ID, post_count ];
rows 459-460
// Run an event once the post has loaded.
$( 'body' ).trigger( 'alnp-post-loaded', triggerParams );

And you recomend to use this trigger next side

$('body').on( 'alnp-post-loaded', function( e, params ) {
var post_limit = 10;
if ( params.post_count == post_limit ) {
// Post count has reached maxiumum amount. No more posts will load.
stop_reading = true;
$( nav_container ).remove(); // Remove post navigation.
return;
}
});

params.post_count? Are you seriously?

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

No branches or pull requests

1 participant