const runtime = require("../../lib/runtime")
const Template = runtime.Template
var VNode = require("virtual-dom/vnode/vnode")
var VText = require("virtual-dom/vnode/vtext")
var createElement = require("virtual-dom/create-element")

var render = require("./layout.html")

var virtualTree = render({
  title: "Fruits",
  fruits: [
    { name: "Kiwi" },
    { name: "Mango" }
  ]
}, { VNodeClass: VNode, VTextClass: VText }, Template)

var rootNode = createElement(virtualTree)
document.body.appendChild(rootNode)
const runtime = require("../../lib/runtime")
const Template = runtime.Template
const VNode = require("virtual-dom/vnode/vnode")
const VText = require("virtual-dom/vnode/vtext")
const createElement = require("virtual-dom/create-element")

const render = require("./layout.html")

const virtualTree = render({
  title: "Fruits",
  fruits: [
    { name: "Kiwi" },
    { name: "Mango" }
  ]
}, { VNodeClass: VNode, VTextClass: VText }, Template)

const rootNode = createElement(virtualTree)
document.body.appendChild(rootNode)
add virtual-dom example