Weave Code
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 Laravel Package

apnet/bootstrap

View on GitHub
Deep Wiki
Context7

Bootstrap Assets Importer

Installation

Add requirements to composer.json:

{
  "require" : {
    "apnet/bootstrap" : "~3.1,<4.0"
  }
}

Configurations

Register ApnetAsseticImporterBundle bundle in the AppKernel.php file

// ...other bundles ...
$bundles[] = new Apnet\AsseticImporterBundle\ApnetAsseticImporterBundle();

Add Bootstrap importer to services.yml

services:
    # bootstrap3 default css
    apnet.assetic.importer.bootstrap_css:
        parent: assetic.importer_path
        arguments:
            - %kernel.root_dir%/../vendor/apnet/bootstrap/app/Resources/assets/stylesheets
            - bootstrap
        tags:
            - { name: apnet.assetic.config_mapper }
    # bootstrap3 js
    apnet.assetic.importer.bootstrap_js:
        parent: assetic.importer_path
        arguments:
            - %kernel.root_dir%/../vendor/apnet/bootstrap/app/Resources/assets/javascripts
            - bootstrap
        tags:
            - { name: apnet.assetic.config_mapper }

Twig

To include Bootstrap into Twig template use imported_asset function:

<link href="{{ imported_asset('bootstrap/bootstrap.min.css') }}" rel="stylesheet" type="text/css" />

and

<script type="text/javascript" src="{{ imported_asset('bootstrap/bootstrap.min.js') }}"></script>
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.
filament/spatie-laravel-tags-plugin
capell-app/block-library
axium/identity
cetria/laravel-dummy-models
cetria/reflection-helper
agropredict/sso-auth-bundle
evolvestudio/spam-protection
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony
develia/geo-bundle
dreamzy/livewire-charts
touchestate-sdk/php-sdk
22h/doctrine-garbage-collection-bundle
agtp/agtp-php
agtp/mod-php
splash/sonata-admin
splash/metadata
splash/openapi