 path = require 'path'
 cheerio = require 'cheerio'
 en = require './app/locale/en'
+zh = require './app/locale/zh-HANS'
 basePath = path.resolve('./app')
 _ = require 'lodash'
 fs = require('fs')

    basedir: basePath
  })

  translate = (key) ->
    html = /^\[html\]/.test(key)
    key = key.substring(6) if html

    t = en.translation
    #TODO: Replace with _.property when we get modern lodash
    translationPath = key.split(/[.]/)
    while translationPath.length > 0


    return out =
      text: t
      type: type

  i18n = (k,v) ->
    return k.i18n.en[a] if 'i18n' in k
