Skip to content

Instantly share code, notes, and snippets.

@Spellhammer
Last active March 26, 2023 17:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Spellhammer/5347655a8de1b4202e7b48cd07b5f56a to your computer and use it in GitHub Desktop.
Save Spellhammer/5347655a8de1b4202e7b48cd07b5f56a to your computer and use it in GitHub Desktop.
FullPageJSJavaScript
jQuery(document).ready( function() {
if( window.angular ) return;
new fullpage('#fullpage', {
//options here
autoScrolling:true,
scrollHorizontally: true,
anchors: ['firstPage', 'secondPage', 'thirdPage'],
lockAnchors: false,
menu: '#div_block-28-6',
afterLoad: function(anchorLink, index) {
jQuery('.fullpage-anchor').removeClass('anchor-active');
jQuery('a[href="#' + index["anchor"] + '"]').addClass('anchor-active');
}
});
//methods
fullpage_api.setAllowScrolling(true);
});
@safafeer
Copy link

Hello, the code is correct, except for line 21. If you put it, the code will not work

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