Closed hackuun closed 7 years ago
Added enableLocationHash
in v1.2.0.
@iamdubx Could you show me how did you implement menuspy along with moveto? I'm facing a lot of problems with that. Thanks in advance ;)
@edphn sure, here is it
<script>
import MoveTo from 'moveto'
import MenuSpy from 'menuspy'
export default {
mounted () {
const moveTo = new MoveTo()
const triggers = document.getElementsByClassName('js-trigger')
for (var i = 0; i < triggers.length; i++) {
moveTo.registerTrigger(triggers[i])
}
const elm = document.querySelector('#main-header')
new MenuSpy(elm, { // eslint-disable-line no-new
threshold: 0,
hashTimeout: 100
})
}
}
</script>
Thanks man 👍
Hello. Am I able to turn off hash anchors changes entirely? I experience weird behavior with it. I am using
menuspy
together withmoveto
.For example,
hashTimeout: 0
does not work at all.