t-template

1.0.2 • Public • Published

t template system

Description

T is a "Outside server" simple template system for static websites.

  • it reads all html file wihtin the folder
  • searchs for template markers
  • injects the content of t/templateFile.html between the markers

Example of a marker

<!-- MainHeader -->
<!-- /MainHeader -->

t would try to find the file ./t/MainHeader and inject it's contents between the two html commentes .

Run it

run the command ./t.js to copy the templates under t/ folders

Easy to work with

To hide the templated code Sublime 3's syntaxFold plugin,

{
    "config":[
        {
            "scope": "text.html.basic",
            "startMarker":"<!-- ",
            "endMarker":"<!-- /"
        },
    ]
}

Readme

Keywords

Package Sidebar

Install

npm i t-template

Weekly Downloads

0

Version

1.0.2

License

MIT

Last publish

Collaborators

  • alfonsodev