Closed LostKobrakai closed 10 years ago
Hi there, I just discovered a strange behavior with link-elements without a href-attribute.
I've added this part to my _header.mustache and the init.js
<a id="nav-toggle" class="nav-toggle">Menu</a> $("#nav-toggle").click(function(e){ e.preventDefault(); });
even though isDefaultPrevented() alerts true, patternlab still tries to load a new page:
isDefaultPrevented()
Not Found The requested URL /patterns/02-organisms-00-global-00-header/null was not found on this server.
After that I can't load different patterns until I fully reload the page.
Adding a href="#" solves the misbehavior.
href="#"
Greetings, Benjamin
@LostKobrakai -
This is actually fixed in dev but I've been holding up a new release as I re-build a bunch of stuff. For now just continue to use the #. Thanks for the heads up.
dev
#
Hi there, I just discovered a strange behavior with link-elements without a href-attribute.
I've added this part to my _header.mustache and the init.js
even though
isDefaultPrevented()
alerts true, patternlab still tries to load a new page:After that I can't load different patterns until I fully reload the page.
Adding a
href="#"
solves the misbehavior.Greetings, Benjamin