scroll spy doesn't work

Djordje Sevic asked 5 years ago

Hello,

I am new to MDB and I have problem with scroll spy. There is my code:

https://pastebin.com/RG0E40iC

https://pastebin.com/VeSuSM1X

Hope that you will solve this problem for me and explain me what was my mistake in code.

Thank you, George


Mateusz Łubianka staff answered 5 years ago

Hi @Djordje Sevic,

You should link js scripts before closing tags. It's better solution than place them in the head tags. Secondly I recommend to initialize functions inside 'document.ready' function. For example:

$( document ).ready(function() {
new WOW().init(); 
});

I can see that you use cdn links with MDB css, js. So you can insall our mdbsnippets extension for VSCode. https://marketplace.visualstudio.com/items?itemName=MDB.mdb-vscode-snippets With mdbsnippets you can just use '!mdb' shortcut and you will get whole Free template with correct css and js links.

Best,


Okey, thank you for that but scroll spy still doesn't work. I can not find problem :/ .

https://pastebin.com/tRe8nf3H


Mateusz Łubianka staff commented 5 years ago

I crated a snippet, check it out: https://mdbootstrap.com/snippets/jquery/mateusz-lubianka/1655957#thing

Best,


Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Answered

Specification of the issue
  • User: Free
  • Premium support: No
  • Technology: General Bootstrap questions
  • MDB Version: -
  • Device: desktop
  • Browser: chrome
  • OS: windows 10
  • Provided sample code: No
  • Provided link: Yes
Tags