https://github.com/codeschubser/bootstrap-twig-components-bundle
Twig Components bundle for Symfony
https://github.com/codeschubser/bootstrap-twig-components-bundle
codeschubser components reusable reusable-components symfony symfony-bundle twig twig-components
Last synced: about 2 months ago
JSON representation
Twig Components bundle for Symfony
- Host: GitHub
- URL: https://github.com/codeschubser/bootstrap-twig-components-bundle
- Owner: codeschubser
- License: mit
- Created: 2025-02-04T07:07:10.000Z (10 months ago)
- Default Branch: master
- Last Pushed: 2025-09-30T06:04:12.000Z (2 months ago)
- Last Synced: 2025-10-12T04:44:57.242Z (about 2 months ago)
- Topics: codeschubser, components, reusable, reusable-components, symfony, symfony-bundle, twig, twig-components
- Language: PHP
- Homepage:
- Size: 927 KB
- Stars: 7
- Watchers: 1
- Forks: 1
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Bootstrap Twig Components Bundle (experimental)
[](https://github.com/codeschubser/twig-components-bundle/actions/workflows/ci.yml)
[](https://github.com/codeschubser/twig-components-bundle/tags)
[](https://codecov.io/gh/codeschubser/twig-components-bundle)
[](https://github.com/codeschubser/twig-components-bundle/blob/master/LICENSE)
> [!WARNING]
> This Bundle is experimental and subject to change in a future release.
A Symfony bundle for the [Twig Components](https://symfony.com/bundles/ux-twig-component/current/index.html) library.
This bundle allows you to create robust and reusable Twig components.
## Requirements
- PHP 8.2 or higher
- Symfony 6.0 or higher
## Features
All components are [Bootstrap](https://getbootstrap.com/) ready. Recommend version is v5.3 or higher. Some components can be extended with icons. [Bootstrap Icons](https://icons.getbootstrap.com/) and [Font Awesome](https://fontawesome.com/) were tested. But other icons are also possible.
## Accessibility
- Optional icons are hidden from the [accessibility API](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-hidden).
- Alerts are decorated with `role="alert"` to send accessible alert event to assistive technology products.
- Dropdowns are decorated with `aria-expanded` and `aria-current`.
- Icons in components are decorated with `aria-hidden` or `aria-label`.
## Usage
- [Installation](docs/index.md)
- Components
- [x] [Alert](docs/alert.md) *Provide contextual feedback messages for typical user actions with a handful of available and flexible options.*
- [x] [Button](docs/button.md) *Provide buttons with support for multiple variants, icon, states, and more.*
- [x] [Breadcrumbs](docs/breadcrumbs.md) *Provide breadcrumb navigation with valid schema.org markup*
- [x] [Card](docs/cards.md) *Provide flexible content containers.*
- [x] [Dropdown](docs/dropdown.md) *Toggleable and contextual overlays.*
- [x] [Icon](docs/icon.md) *Reusable icon component*
- [ ] Modal *TBD*
- [ ] Toast *TBD*
## Development
During development, composer provides a large number of user-specific scripts that are intended to ensure code quality, among other things. A list and the corresponding description can be called up via `composer list`. These scripts are also used in the Github workflows.
## Contributing
If you want to contribute to the project and make it better, your help is very welcome. For major changes, please open an issue first to discuss what you would like to change. Please make sure to update tests as appropriate.
## License
This bundle is licensed under the [MIT License](LICENSE).