CodeIgniter Forums

Full Version: CI4 and Bootstrap
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Is there any built in component for bootstrap 4 such that you can activate conveniently in <head>?
Or is still same as CI3 where one has to create assets/css folders in folder public

<!-- Bootstrap core CSS -->
    <link rel="stylesheet" type="text/css" href="assets/css/bootstrap.min.css">
Like CI3, CI4 is as CSS-framework neutral as it can be.
If you use a template system, then the links to Bootstrap4 (or whatever) could be specified just once.
See for an example.
My Assets library can help with this:

Right now you need to setup each of the pieces, but the next major version will have built-in support for some of the major popular packages.

composer require tatter/assets
composer require twbs/bootstrap4

For an example of an automated version of this right now see:

Pay attention to composer.json,, app/Config/Assets.php, and app/Views/templates/header.php