(Vegvisir 2, Vegvisir 3)
vegvisir.Navigation()
constructorThe Vegvisir navigation constructor is used to create a new instance of Navigation
. This is the first step to creating a custom navigation.
url
A URL
object or string with to a location on the same origin as the initiator.
options
An optional object containing vegvisir.Navigation.options
overrides.
Navigation
instanceA Navigation
object instance. Use the instance method .navigate()
to navigate an, or many element(s) in the DOM.
Different ways to initialize vegvisir.Navigation
with a location that will open /public/some-page.php
relative from project root.
With strings:
= Snippet::put("docs/API/JS/Navigation/constructor/example-0-0", Snippet::JAVASCRIPT) ?> = Snippet::put("docs/API/JS/Navigation/constructor/example-0-1", Snippet::JAVASCRIPT) ?>With URL objects:
= Snippet::put("docs/API/JS/Navigation/constructor/example-0-2", Snippet::JAVASCRIPT) ?>