Giter Site home page Giter Site logo

fuel-jammit's Introduction

Jammit

Allows for the ruby gem Jammit to be used with Fuel.

To use place a Config/assets.yml file at the project root directory. For example, if your Project has a directory structure as follows:

~/Foo
~/Foo/Fuel
~/Foo/public

your config would go...

~/Foo/config/assets.yml

An example config file looks like...

# jammit manifest
# Tip: NEVER NAME A GROUP THE SAME AS A DIR BEING INCLUDED
embed_assets: datauri # doesn't support ie7 and below
compress_assets: off
template_function: _.template
package_path: production

javascripts:
    base:
        - public/assets/vendor/js/jquery-1.7.1.js
        - public/assets/vendor/jquery-ui-1.8.16.custom/js/jquery-ui-1.8.16.custom.js
        - public/assets/vendor/js/underscore-1.2.3.js
stylesheets:
    base:
        - public/assets/css/fuel.css
        - public/assets/vendor/jquery-ui-1.8.16.custom/css/smoothness/jquery-ui-1.8.16.custom.css

To use thr Jammit class in your project include jammit in the packages config setting and call Jammit\Jammit::load() in a controller to load all assets for rendering. Execute echo Jammit\Jammit::render('group') in a view to render assets in the view. The render function works nearly identical to Fuel's Asset::render('group').

fuel-jammit's People

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.