Download the PHP package dnafactory/module-bootstrap without Composer
On this page you can find all versions of the php package dnafactory/module-bootstrap. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download dnafactory/module-bootstrap
More information about dnafactory/module-bootstrap
Files in dnafactory/module-bootstrap
Package module-bootstrap
Short Description Magento 2 Bootstrap source integration
License BSD-3-Clause
Informations about the package module-bootstrap
Bootstrap source integration for Magento 2
This Magento 2 module provides a full integration of Bootstrap 4 's sources.
This is not a porting!
It uses dnafactory/module-scss to integrate the official Bootstrap 4 package so it can be built with your Magento 2 theme configuration.
Installation
The extension must be installed via composer:
How to use CSS
By default, the extension will deploy a DNAFactory_Bootstrap/css/bootstrap.css build based on all Magento .less lib values defined in your active theme. So, if you want to change some theme specific style as can be the primary color, you can do it by simply editing @themecolorprimary in your css/sources/_theme.less file, as usual.
However, you can change these values or add other custom variables using one or more of the extension points provided:
- source/scss/themes/_extends.scss where you can put your custom scss vars and other useful stuff, which we will cover later in this document.
- source/scss/_extends.scss where you can put Bootstrap-specific customizations in scss
- source/scss/_extend.scss module related extension file, for small customizations.
Well, what if I'm working on a custom theme?
Just put your .less theme variables file reference in source/scss/themes/_extends.scss:
or, when your variables file is stored in a theme-level directory (most common case):
For example, using
from view/frontend/web/css/source/scss/themes/_magento.scss, it will point to YourVendor/YourTheme/your_locale/css/source.
Refer to dnafactory/module-scss's doc, for more info about the @vars_import directive.
How to use JS
Bootstrap js plugins are designed to run on demand and they can be requested using these aliases:
- bs.alert
- bs.button
- bs.carousel
- bs.collapse
- bs.dropdown
- bs.modal
- bs.popover
- bs.scrollspy
- bs.tab
- bs.toast
- bs.tooltip
Simply add the required plugin to your module's dependencies.
Note for Developers
To update one or more dependencies (as Bootstrap or popper.js) to the latest one, just use npm as needed and then run:
Happy Coding
All versions of module-bootstrap with dependencies
dnafactory/module-scss Version ^1.0
dnafactory/module-critical Version ^1.0|dev-develop