CrossClj

0.1.0 docs

SourceDocs



RECENT

    ring-cljsjs

    Clojars

    Mar 6, 2016


    OWNER
    Juho Teperi
    Metosin
    Tampere, Finland
    juho.teperi@iki.fi
    deraen.github.io/

    Readme

    Index of all namespaces


    The README below is fetched from the published project artifact. Some relative links may be broken.

    Ring-Cljsjs

    Build Status

    Ring middleware to serve static assets from cljsjs.

    Installation

    Include the following dependency in your project dependencies:

    [ring-cljsjs "0.1.0"]
    

    Usage

    Require the middleware and add it to your handler.

    (require '[ring.middleware.cljsjs :refer [wrap-cljsjs]])
    
    (def app (wrap-cljsjs handler)
    

    Cljsjs assets will then be served from the following path:

    /cljsjs/<package>/<asset path>
    

    For example, if you include the [cljsjs/react-mdl “1.4.3-0”] dependency, then the minified material CSS will be available at:

    /cljsjs/react-mdl/material.min.css
    

    By default assets are placed on the /cljsjs path. You can change the path by specifying prefix in a options map.

    (def app (web-cljsjs handler {:prefix "/cljsjs"}))
    

    License

    Copyright © 2016 Juho Teperi

    Based on ring-webjars
    Copyright © 2015 James Reeves

    Released under the MIT license.