Skip to content

Instantly share code, notes, and snippets.

@kabdessamad1
Created August 3, 2015 18:26
Show Gist options
  • Save kabdessamad1/1d8b2d62d83067b2851f to your computer and use it in GitHub Desktop.
Save kabdessamad1/1d8b2d62d83067b2851f to your computer and use it in GitHub Desktop.
install twitter Bootstrap and jQuery to Symfony2
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>{% block title %}Welcome!{% endblock %}</title>
{% block stylesheets %}
{% stylesheets filter='cssrewrite'
'%kernel.root_dir%/../vendor/twbs/bootstrap/dist/css/bootstrap.css'
'%kernel.root_dir%/../vendor/twbs/bootstrap/dist/css/bootstrap-theme.css'
'@WbttcBlogBundle/Resources/public/css/custom.css'
%}
<link rel="stylesheet" href="{{ asset_url }}">
{% endstylesheets %}
{% endblock %}
<link rel="icon" type="image/x-icon" href="{{ asset('favicon.ico') }}" />
</head>
<body>
<div class="container">
{{ include('_nav.html.twig') }}
{% block body %}{% endblock %}
</div>
{% block javascripts %}
{% javascripts
'%kernel.root_dir%/../vendor/components/jquery/jquery.js'
'%kernel.root_dir%/../vendor/twbs/bootstrap/dist/js/bootstrap.js'
%}
<script src="{{ asset_url }}"></script>
{% endjavascripts %}
{% endblock %}
</body>
</html>
"require": {
"twbs/bootstrap": "3.3.*",
"components/jquery": "1.11.*"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment