Hello,
I would like to announce an implementation of ERB/JSP/etc -like
approach for templating with (I really believe) clear and idiomatic
syntax and design decisions.
Detailed description and code:
http://github.com/Flamefork/fleet
On Clojars:
http://clojars.org/fleet
I would appreciate any cr
Despite I agree that writing code and markup in common
ASP way is evil, I must argue that doing so or using provided abilities wisely is up to you.
I see no reasons to divide (not so) complex display/
markup logic and e.g. HTML.
But I see reason to have them together: fragility.
When you're using
I've encountered the same problem (as far as I understood) in Fleet.
My solution is
http://github.com/Flamefork/fleet/blob/master/src/fleet/loader.clj#L55
There code comes from String, but you can use FileReader instead of
StringReader.
File path must be specified additionally, but this should be
Hello Ari,
I've tried to reproduce your case and it works for me. I use the following
project.clj:
(defproject playground "0.1.0"
:dependencies [[jayq "2.0.0"]]
:min-lein-version "2.0.0"
:source-paths ["src"]
:plugins [[lein-cljsbuild "0.2.10"]]
:cljsbuild {:builds
[{:so
It's very simple, you only need to
1. create a directory with all needed templates
2. (fleet-ns templates "path/to/that_dir" [:fleet :xml])
3. use templates.* functions just as any other
Give it a try :)
On Sep 2, 1:39 am, Sean Corfield wrote:
> On Wed, Sep 1, 2010 at 2:14 PM, Saul Hazledine wr
Hello!
Fleet have parameters for sure :)
Creating template from string:
(fleet [post] "<(post :body)>")
returns function of single argument post.
(fleet [post, comments] "<(post :body)> <(comments :count)>")
returns function of two arguments post, comments.
Creating multiple templates from dir: