Add templates as their own module
This commit is contained in:
parent
244d372fef
commit
732fe30756
|
@ -0,0 +1,7 @@
|
|||
const
|
||||
baseTemplate*: string = staticRead "./templates/layout.mustache"
|
||||
errorTemplate*: string = staticRead "./templates/error.mustache"
|
||||
indexTemplate*: string = staticRead "./templates/index.mustache"
|
||||
usersTemplate*: string = staticRead "./templates/users.mustache"
|
||||
tweetsTemplate*: string = staticRead "./templates/tweets.mustache"
|
||||
submitTemplate*: string = staticRead "./templates/submit.mustache"
|
|
@ -1,13 +1,5 @@
|
|||
import asyncdispatch, db_sqlite, httpclient, jester, moustachu, os, shorturl,
|
||||
strutils, tables, times, twtxt, typetraits
|
||||
|
||||
const
|
||||
baseTemplate*: string = staticRead "./templates/layout.mustache"
|
||||
errorTemplate*: string = staticRead "./templates/error.mustache"
|
||||
indexTemplate*: string = staticRead "./templates/index.mustache"
|
||||
usersTemplate*: string = staticRead "./templates/users.mustache"
|
||||
tweetsTemplate*: string = staticRead "./templates/tweets.mustache"
|
||||
submitTemplate*: string = staticRead "./templates/submit.mustache"
|
||||
strutils, tables, templates/all, times, twtxt, typetraits
|
||||
|
||||
let
|
||||
db = open("data/twtxt.db", nil, nil, nil)
|
||||
|
|
Loading…
Reference in New Issue