Skip to content
This repository has been archived by the owner on May 27, 2022. It is now read-only.

jimbru/htmhell

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

htmhell

A really garbage HTML library.

Contains all sorts of functionality:

  • HTML escaping that probably isn't insecure
  • America's #1 worst templating system

Clojars Project

Usage

  1. Add this as a dependency in your project.clj:
[htmhell "0.1.0"]
  1. Write your garbage code:
(require '[htmhell.core :as html])

(def my-html-escaped-string (html/escape "<script>alert('Jerry, hello!');</script>"))
  1. Write your garbage template:
<!-- resources/index.html -->
<html>
  <div>Kramer's first name is {{name}}.</div>
</html>
  1. Render your garbage data:
(def my-html (html/render-template "index.html" {:name "Cosmo"}))

FAQs

  1. Does it do <blank>?

No.

  1. How does it do <blank>?

Regex, mostly.

  1. Is there any redeeming value here?

You be the judge!

License

Copyright © 2015 Jim Brusstar

Distributed under the Eclipse Public License either version 1.0 or (at your option) any later version.

About

A really garbage HTML library.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published