Skip to content

Instantly share code, notes, and snippets.

Created August 25, 2013 17:42
What would you like to do?
Barebones nvALT template with [[linking]] built-in
<!DOCTYPE html>
<html lang="en">
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<style type="text/css">
<div id="wrapper">
<h1 class="doctitle">{%title%}</h1>
<div id="contentdiv">
</div> <!-- end of #container -->
window.onload = function(e){
var container = document.getElementById("wrapper");
container.innerHTML = container.innerHTML.replace(/\[\[(.*?)\]\]/g,"<a href='nvalt://find/$1'>$1</a>");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment