bmatzner/marionette-bundle

This package is abandoned and no longer maintained. No replacement package was suggested.

MarionetteJS Bundle for Symfony2

Installs: 412

Dependents: 1

Suggesters: 0

Security: 0

Stars: 1

Watchers: 1

Forks: 2

Open Issues: 0

Language:JavaScript

Type:symfony-bundle

1.8.8 2014-06-17 13:20 UTC

README

Current Version

MarionetteJS v1.8.8

Requirements

MarionetteJS requires Backbone and a number of dependencies included in this package.

Installation

Add bundle to your composer.json file

// composer.json

{
    "require": {
		// ...
        "bmatzner/marionette-bundle": "~1.8"
    }
}

Add bundle to your application kernel

// app/AppKernel.php

public function registerBundles()
{
    $bundles = array(
        // ...
	new Bmatzner\MarionetteBundle\BmatznerMarionetteBundle(),
	new Bmatzner\UnderscoreBundle\BmatznerUnderscoreBundle(),
	new Bmatzner\Json2Bundle\BmatznerJson2Bundle(),
	new Bmatzner\JQueryBundle\BmatznerJQueryBundle(),
	new Bmatzner\BackboneBundle\BmatznerBackboneBundle(),
        // ...
    );
}

Download the bundle using Composer

$ php composer.phar update bmatzner/marionette-bundle

Install assets

Given your server's public directory is named "web", install the public vendor resources

$ php app/console assets:install web

Optionally, use the --symlink attribute to create links rather than copies of the resources

$ php app/console assets:install --symlink web

Usage

Install and reference the dependencies for Marionette:

<script type="text/javascript" src="{{ asset('bundles/bmatznerjson2/js/json2.min.js') }}"></script>
<script type="text/javascript" src="{{ asset('bundles/bmatznerjquery/js/jquery.min.js') }}"></script>
<script type="text/javascript" src="{{ asset('bundles/bmatznerunderscore/js/underscore.min.js') }}"></script>
<script type="text/javascript" src="{{ asset('bundles/bmatznerbackbone/js/backbone.min.js') }}"></script>
<script type="text/javascript" src="{{ asset('bundles/bmatznermarionette/js/backbone.marionette.min.js') }}"></script>

Alternatively, use Lo-Dash as a drop-in replacement for Underscore (also available as a Symfony bundle "bmatzner/lodash-bundle")

Licenses

Refer to the source code of the included files for license information

References

  1. http://marionettejs.com/
  2. http://backbonejs.org/
  3. http://symfony.com/