Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Bootstrap Bundle Laravel Package

webeweb/bootstrap-bundle

Symfony bundle that integrates Bootstrap into your applications, providing bundled assets, Twig helpers, form themes, and UI utilities so you can build responsive, consistent interfaces with less configuration and cleaner templates.

View on GitHub
Deep Wiki
Context7

Getting Started

  1. Install the bundle

    composer require webeweb/bootstrap-bundle
    

    The package is archived and last tagged in Dec 2023, so expect a pinned version compatible with your Symfony version (the bundle was built for Symfony 4/5-era apps).

  2. Register it

    • On Symfony Flex with symfony/flex, the bundle is usually auto-registered into config/bundles.php.
    • Otherwise add it manually:
      // config/bundles.php
      Webeweb\BootstrapBundle\WebewebBootstrapBundle::class => ['all' => true],
      
  3. Publish the bundled assets

    php bin/console assets:install --symlink public/
    

    This exposes the CSS/JS under public/bundles/webewebbootstrap/... (confirm the exact folder name in the repo's Resources/public directory).

  4. First use case — wire Bootstrap into your base layout in templates/base.html.twig:

    <link rel="stylesheet" href="{{ asset('bundles/webewebbootstrap/css/bootstrap.min.css') }}">
    ...
    <script src="{{ asset('bundles/webewebbootstrap/js/bootstrap.bundle.min.js') }}"></script>
    

    Start here: load a navbar + modal in one template to confirm both CSS and the JS bundle (which includes Popper for 4.x/5.x) resolve correctly before rolling it out to other layouts.

Look first at Resources/public/ (what versions ship) and Resources/views/ (whether any Twig macros/blocks are provided) since there is no full docs site — the README and directory tree are your API reference.

Implementation Patterns

Layout inheritance. Centralize asset inclusion in a single base.html.twig and have pages {% extends %} it. This is the whole point of the bundle — one canonical, cache-friendly reference rather than per-page CDN links.

Version selection. The bundle advertises Bootstrap 3.x/4.x/5.x and companion jQuery/Popper. Pin the version you need by referencing the specific file paths under Resources/public. Keep an explicit mapping in config/services.yaml or a Twig variable (e.g. bootstrap_version: 5) so you can swap versions in one place:

# config/services.yaml
parameters:
    bootstrap_version: '5'
<script src="{{ asset('bundles/webewebbootstrap/js/bootstrap#' ~ bootstrap_version ~ '.bundle.min.js') }}"></script>

(Adjust path to whatever filenames actually ship.)

Load order matters. For Bootstrap 4 (and 3), include jQuery and Popper before the Bootstrap JS. Bootstrap 5 dropped jQuery — don't include it unless you need it elsewhere. Bootstrap's bundle.min.js already contains Popper, so don't double-load.

Pairing with Webeweb theme bundles. The bundle is designed to sit alongside Webeweb core/theme bundles. In practice: let the theme bundle own custom components/overrides, and let this bundle own the upstream Bootstrap files. Keep your import order as Bootstrap → theme overrides so theme rules win.

Modern asset pipelines. If the project uses Webpack Encore or Symfony AssetMapper, you can bypass this bundle and import "bootstrap" from node_modules instead. Only pull in the bundle when you want zero-Node, Symfony-native assets — that's the trade-off it exists for.

Twig namespace. If the bundle exposes templates, reference them with the bundle namespace (@WebewebBootstrap/...) rather than hard-coded bundles/ paths — the Twig loader resolves this automatically.

Gotchas and Tips

  • Archived project — pin and audit. Last release 2023-12-04, 11 stars, 0 dependents, and explicitly archived. Pin a specific version in composer.json ("webeweb/bootstrap-bundle": "x.y.*"), and treat this as a vendored convenience layer, not something that will track future Symfony major releases. Check it installs cleanly against your PHP/Symfony version before committing.
  • assets:install is required in every environment. A fresh deploy (or a CI build without the public symlink) will 404 the CSS/JS. Add assets:install to your deploy pipeline and use --symlink locally, copy mode in production.
  • Stale cached assets. Bump a query string on the asset path or rely on Symfony's version config (framework.assets.version) when you change the shipped Bootstrap version, otherwise browsers keep the old CSS.
  • Path-name guesswork. With no formal docs, the bundle name (webewebbootstrap? WebewebBootstrapBundle?) determines the bundles/... URL. Verify by running bin/console assets:install and listing public/bundles/, or via bin/console debug:twig for template namespaces.
  • JS order bugs. Symptoms like "dropdown doesn't open" or "tooltip is defined but nothing happens" almost always mean Popper/jQuery loaded after Bootstrap. Load dependencies first, or use the bundle.min.js build.
  • Configuration node may not exist. Don't assume webeweb_bootstrap: keys work — run bin/console config:dump-reference webeweb_bootstrap (or the bundle's actual alias) to discover what's configurable before writing YAML.
  • Debugging template loading. bin/console debug:twig --filter=<pattern> shows whether templates are exposed under @WebewebBootstrap; bin/console debug:container <service> helps if a Twig extension is registered.
  • Extension points. Anything custom you need (extra fonts, theme overrides, CSS variables) should live in your own templates/ and assets/ — don't edit the bundle's Resources/public in place, since composer update and assets:install will overwrite it.
  • Modern alternative for greenfield work. If you're starting fresh, evaluate Stimulus/Encore or AssetMapper + bootstrap npm package instead — this bundle earns its keep only in Symfony-native legacy stacks that already depend on Webeweb bundles.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
middlewares/firewall
qubiqx/montapacking
nyoncode/laravel-package-console
pnscripts/filament-broadquill-lite
pnscripts/laravel-sentfold-lite
vleap/mx-sdk-laravel-internal
twidpay/utils
htetmyathlaing/scout-elasticsearch-driver
artisan-toolbox/front-awesome
ls/client-assistant
users-au/laravel-client
robertmarney/lara-hierarchial-collections
simonschaufi/rule-doc-generator
emissaoja/emissaoja
blackbricksoftware/gravityforms-civicrm-form-processor
al-rahabi/fancy-crud
jinas/dhivatar-component
mltstephane/laravel-quality
bernskiold/laravel-talentlms
bernskioldmedia/laravel-form-architect