Add my recipe repository endpoint in your project's composer.json
as described in the
Symfony documentation.
{
"extra": {
"symfony": {
"endpoint": [
"https://api.github.com/repos/neuralglitch/symfony-recipes/contents/index.json",
"flex://defaults"
]
}
}
}
Warning
If you don't, Composer will not use the Symfony Flex recipe for this bundle and you will need to follow these manual installation instructions.
Tip
The extra.symfony
key will most probably already exist in your composer.json
. In that case, add the endpoint
key to the existing extra.symfony
entry.
composer require neuralglitch/bootstrap-theme-switch
Execute the appropriate commands to build the frontend, if necessary.
templates/base.html.twig
<html
data-bs-theme="{{ app.session.get('_theme', 'light') }}"
data-system-theme="{{ app.session.get('_is_system_theme', '0') }}">
i.e. templates/partials/footer.html.twig
...
{% include '@BootstrapThemeSwitch/button.html.twig' %}
...
or
...
{% include '@BootstrapThemeSwitch/select.html.twig' %}
...
If that's not enough, refer to the advanced usage instructions.
Warning
Wiithout the Symfony Flex recipe, Composer will not completely remove the bundle and you will need to follow these manual removal instructions.
composer remove neuralglitch/bootstrap-theme-switch
Execute the appropriate commands to build the frontend, if necessary.
Copyright (c) neuralglit.ch