website/public/docs/API/JS/Navigation/bindElements.php

36 lines
No EOL
1.2 KiB
PHP

<?= VV::include("modules/snippet/Snippet.php") ?>
<?php // General information ?>
<section class="md">
<container>
<p>(Vegvisir 2, Vegvisir 3)</p>
<h1><code>vegvisir.Navigation.bindElements()</code></h1>
<p>Trigger automatic binding of unbound tags.</p>
</container>
</section>
<section class="md">
<container>
<h1>Description</h1>
<?= Snippet::put("docs/API/JS/Navigation/bindElements/description", Snippet::JAVASCRIPT) ?>
<p>Bind event listeners for <a href=""><code>HTMLAnchorElement</code></a> tags and other tags with a <a href=""><code>vv</code></a> attribute that haven't already been bound.</p>
<p>This method is runned automatically after a finished Vegvisir navigation.</p>
</container>
</section>
<?php // Examples ?>
<section class="md">
<container>
<h1>Examples</h1>
</container>
</section>
<section class="md inset">
<container>
<h2>Basic usage</h2>
<p>In this example we will programatically create and append an anchor tag to the DOM and use this method to bind it.</p>
<?= Snippet::put("docs/API/JS/Navigation/bindElements/example-0-0", Snippet::JAVASCRIPT) ?>
</container>
</section>
<?php // Contribute ?>
<?= VV::include("modules/docs/contribute") ?>
<?= VV::shell("shells/docs") ?>