2017 © Pedro Peláez
 

symfony-bundle bootstrap-bundle

Bootstrap handler bundle

image

hackzilla/bootstrap-bundle

Bootstrap handler bundle

  • Monday, January 12, 2015
  • by hackzilla
  • Repository
  • 1 Watchers
  • 0 Stars
  • 93 Installations
  • CSS
  • 0 Dependents
  • 1 Suggesters
  • 0 Forks
  • 0 Open issues
  • 11 Versions
  • 0 % Grown

The README.md

Boostrap Helper Bundle for Symfony2

Requirements

  • java
  • nodejs (npm & less)
  • cssembed [https://github.com/nzakas/cssembed/downloads]
  • yuicompressor [https://github.com/yui/yuicompressor/downloads]

System Setup

For ubuntu, run the following commands to install necessary dependencies., (*1)

apt-get install java-common nodejs npm
npm install -g less

Installation

Add HackzillaBootstrapBundle in your composer.json:, (*2)

{
    "require": {
        "hackzilla/bootstrap-bundle": "~0.2",
    }
}

Now tell composer to download the bundle by running the command:, (*3)

``` bash $ php composer.phar update hackzilla/bootstrap-bundle, (*4)


Composer will install the bundle into your project's `vendor/hackzilla` directory. ### Step 2: Enable the bundle Enable the bundle in the kernel: ``` php <?php // app/AppKernel.php public function registerBundles() { $bundles = array( // ... new Hackzilla\Bundle\BootstrapBundle\HackzillaBootstrapBundle(), // ... // Your application bundles ); }

Copy cssembed.jar, and yuicompressor.jar to /app/Resources/java/, (*5)

Add to config.yml, (*6)

# Twig Configuration
twig:
    form:
        resources:
          - 'HackzillaBoostrapBundle:Form:fields.html.twig'

If nodejs path is different on your system, then update it here., (*7)

Possible values are: * /usr/local/bin/node * /usr/bin/node * /usr/bin/nodejs, (*8)

# Assetic Configuration
assetic:
    java: /usr/bin/java
    filters:
      cssembed:
        jar: %kernel.root_dir%/Resources/java/cssembed-<version>.jar
      cssrewrite: ~
      yui_js:
        jar: %kernel.root_dir%/Resources/java/yuicompressor-<version>.jar
      less:
          node: /usr/local/bin/node
          node_paths: [/usr/local/lib/node_modules]
          apply_to: "\.less$"
    assets:
      bootstrap_js:
          inputs:
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/affix.js'
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/alert.js'
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/button.js'
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/carousel.js'
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/collapse.js'
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/dropdown.js'
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/modal.js'
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/tooltip.js'
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/popover.js'
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/scrollspy.js'
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/tab.js'
              - '%kernel.root_dir%/../vendor/twbs/bootstrap/js/transition.js'
          filters: [?yui_js]
      bootstrap_less:
          inputs:
              - '@HackzillaBootstrapBundle/Resources/less/compile.less'
          filters: [less,cssembed]

Fonts

in web directory create symlink to the bootstrap fonts, (*9)

ln -s ../vendor/twbs/bootstrap/fonts, (*10)

(Re)Generate bootstrap.js and bootstrap.css

app/console assetic:dump --env=prod --no-debug;
app/console assetic:dump --env=dev;

Advanced usage

Copy @HackzillaBootstrapBundle/Resources/less/compile.less and @HackzillaBootstrapBundle/Resources/less/variables.less to your own folder resources folder, and update bootstrap_less section in your config., (*11)

~~Alternatively copy @HackzillaBootstrapBundle/Resources/less/variables.less to /app/Resources/HackzillaBootstrapBundle/less/variables.less~~, (*12)

The Versions

12/01 2015

dev-master

9999999-dev

Bootstrap handler bundle

  Sources   Download

MIT

The Requires

 

12/01 2015

0.9

0.9.0.0

Bootstrap handler bundle

  Sources   Download

MIT

The Requires

 

06/01 2015

0.8

0.8.0.0

Bootstrap handler bundle

  Sources   Download

MIT

The Requires

 

19/07 2014

0.7.1

0.7.1.0

Bootstrap handler bundle

  Sources   Download

MIT

The Requires

 

19/07 2014

0.7

0.7.0.0

Bootstrap handler bundle

  Sources   Download

MIT

The Requires

 

27/04 2014

0.6

0.6.0.0

Bootstrap handler bundle

  Sources   Download

MIT

The Requires

 

19/04 2014

0.5

0.5.0.0

Bootstrap handler bundle

  Sources   Download

MIT

The Requires

 

19/04 2014

0.4

0.4.0.0

Bootstrap handler bundle

  Sources   Download

MIT

The Requires

 

19/04 2014

0.3.1

0.3.1.0

Bootstrap handler bundle

  Sources   Download

MIT

The Requires

 

19/04 2014

0.3

0.3.0.0

Bootstrap handler bundle

  Sources   Download

MIT

The Requires

 

19/04 2014

0.2

0.2.0.0

Bootstrap handler bundle

  Sources   Download

MIT

The Requires