1
0
mirror of https://github.com/strongdm/comply synced 2024-12-25 23:01:37 +00:00
comply/vendor/github.com/yosssi/ace
2018-05-15 14:13:11 -07:00
..
.gitignore Initial commit 2018-05-15 14:13:11 -07:00
ace.go Initial commit 2018-05-15 14:13:11 -07:00
action.go Initial commit 2018-05-15 14:13:11 -07:00
comment.go Initial commit 2018-05-15 14:13:11 -07:00
compile.go Initial commit 2018-05-15 14:13:11 -07:00
doc.go Initial commit 2018-05-15 14:13:11 -07:00
element_base.go Initial commit 2018-05-15 14:13:11 -07:00
element.go Initial commit 2018-05-15 14:13:11 -07:00
empty_element.go Initial commit 2018-05-15 14:13:11 -07:00
file.go Initial commit 2018-05-15 14:13:11 -07:00
formatter.go Initial commit 2018-05-15 14:13:11 -07:00
helper_method_conditional_comment.go Initial commit 2018-05-15 14:13:11 -07:00
helper_method_content.go Initial commit 2018-05-15 14:13:11 -07:00
helper_method_css.go Initial commit 2018-05-15 14:13:11 -07:00
helper_method_doctype.go Initial commit 2018-05-15 14:13:11 -07:00
helper_method_include.go Initial commit 2018-05-15 14:13:11 -07:00
helper_method_javascript.go Initial commit 2018-05-15 14:13:11 -07:00
helper_method_yield.go Initial commit 2018-05-15 14:13:11 -07:00
html_comment.go Initial commit 2018-05-15 14:13:11 -07:00
html_tag.go Initial commit 2018-05-15 14:13:11 -07:00
LICENSE Initial commit 2018-05-15 14:13:11 -07:00
line.go Initial commit 2018-05-15 14:13:11 -07:00
options.go Initial commit 2018-05-15 14:13:11 -07:00
parse.go Initial commit 2018-05-15 14:13:11 -07:00
plain_text_inner.go Initial commit 2018-05-15 14:13:11 -07:00
plain_text.go Initial commit 2018-05-15 14:13:11 -07:00
read.go Initial commit 2018-05-15 14:13:11 -07:00
README.md Initial commit 2018-05-15 14:13:11 -07:00
result.go Initial commit 2018-05-15 14:13:11 -07:00
source.go Initial commit 2018-05-15 14:13:11 -07:00
wercker.yml Initial commit 2018-05-15 14:13:11 -07:00

Ace - HTML template engine for Go

wercker status GoDoc

Overview

Ace is an HTML template engine for Go. This is inspired by Slim and Jade. This is a refinement of Gold.

Example

= doctype html
html lang=en
  head
    title Hello Ace
    = css
      h1 { color: blue; }
  body
    h1 {{.Msg}}
    #container.wrapper
      p..
        Ace is an HTML template engine for Go.
        This engine simplifies HTML coding in Go web application development.
    = javascript
      console.log('Welcome to Ace');

becomes

<!DOCTYPE html>
<html lang="en">
  <head>
    <title>Hello Ace</title>
    <style type="text/css">
      h1 { color: blue; }
    </style>
  </head>
  <body>
    <h1>Hello Ace</h1>
    <div id="container" class="wrapper">
      <p>
        Ace is an HTML template engine for Go.<br>
        This engine simplifies HTML coding in Go web application development.
      </p>
    </div>
    <script type="text/javascript">
      console.log('Welcome to Ace');
    </script>
  </body>
</html>

Features

Making Use of the Go Standard Template Package

Ace fully utilizes the strength of the html/template package. You can embed actions of the template package in Ace templates. Ace also uses nested template definitions of the template package and Ace templates can pass pipelines (parameters) to other templates which they include.

Simple Syntax

Ace has a simple syntax and this makes template files simple and light.

Caching Function

Ace has a caching function which caches the result data of the templates parsing process. You can omit the templates parsing process and save template parsing time by using this function.

Binary Template Load Function

Ace has a binary template load function which loads Ace templates from binary data in memory instead of template files on disk. You can compile your web application into one binary file by using this function. go-bindata is the best for generating binary data from template files.

Getting Started

Please check the following documentation.

  • Getting Started - shows the getting started guide.
  • Examples - shows the examples of the web applications which use the Ace template engine.

Documentation

You can get the documentation about Ace via the following channels:

  • Documentation - includes the getting started guide and the syntax documentation.
  • GoDoc - includes the API documentation.

Discussion & Contact

You can discuss Ace and contact the Ace development team via the following channels:

Contributions

Any contributions are welcome. Please feel free to create an issue or send a pull request.

Renderers for web frameworks

Tools

  • vim-ace - Vim syntax highlighting for Ace templates
  • ace-tmbundle - TextMate/Sublime syntax highlighting for Ace templates
  • atom-ace - Atom Editor syntax highlighting for Ace templates

Projects using Ace

Here is the list of the projects using Ace. Please feel free to add your awesome project to the list!