Weave 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
Typeahead Bundle

Typeahead Bundle Laravel Package

lifo/typeahead-bundle

Symfony bundle that integrates Twitter Typeahead.js into forms and templates, adding AJAX-powered autocomplete and suggestion fields with minimal configuration. Provides helpers for connecting typeahead inputs to controllers and data sources.

View on GitHub
Deep Wiki
Context7

A Symfony bundle that provides an autocomplete Typeahead form type compatible with Bootstrap v2|v3

Frequently asked questions about Typeahead Bundle
Can I install lifo/typeahead-bundle in a Laravel application?
Not practically. It is a Symfony2 bundle built on the Symfony Form component, dependency injection container, and Twig form themes, none of which Laravel uses. Composer resolution will also likely fail because it pins symfony/form to the 2.x line while modern Laravel ships Symfony 6/7 components. The only realistic use is as a reference design for an autocomplete widget.
Does lifo/typeahead-bundle support Laravel 9, 10, or 11?
No. The package predates those releases, has no Laravel service provider or facade, and is not designed for Laravel's form or routing layers. Its last release was December 2018, so there is no Laravel 9/10/11 support to speak of. Using it would require ignoring platform requirements and maintaining a parallel Symfony 2 dependency tree.
What PHP and Symfony versions does lifo/typeahead-bundle require?
It is a 2018-era Symfony2 bundle that expects the Symfony 2.x component line and does not declare PHP 8.x support. You should expect deprecated syntax and platform-check failures on modern PHP runtimes. Verify against your target PHP before assuming even a fork is cheap.
How do I build a typeahead autocomplete field natively in Laravel?
Use a Blade component or Livewire component for the input, an invokable controller returning JsonResponse for suggestions, and a maintained JavaScript library such as Tom Select, Choices.js, or Alpine plus fetch. The bundle's portable ideas are the option contract (source URL, displayKey, valueKey, minimum query length, debounce) and a [{value, label}] JSON shape. Expect roughly one to three developer-days including tests.
What is the Laravel equivalent of the Symfony form type provided by this bundle?
A Blade component such as x-typeahead or a Livewire component. The Symfony AbstractType and OptionsResolver wiring is Symfony-specific and has no direct Laravel counterpart. The Twig form theme becomes a Blade partial loaded through @vite.
Is lifo/typeahead-bundle maintained and safe for production?
No. It has about 21 stars, zero dependents, a single maintainer, and its last release was December 2018, so there is no peer review or security response channel. Symfony 2, Bootstrap 3, and typeahead.js are all end-of-life. If suggestion templates render remote HTML unescaped, that is an XSS vector you would own permanently.
Will Composer let me install lifo/typeahead-bundle alongside Laravel?
Almost certainly not. The package is expected to pin symfony/form to the 2.x line, while Laravel 9/10/11 ship Symfony 6/7 components. You would need --ignore-platform-reqs and a parallel Symfony 2 tree, which is not a viable production posture. Check composer why-not output before spending time on it.
How do I map the bundle's AJAX suggestion endpoint to Laravel routes?
Replace the Symfony controller JSON action with a Laravel route pointing to an invokable controller that returns response()->json([...]). Keep the same response shape the JavaScript expects, typically an array of {value, label} objects. Server-side search can be backed by Scout or a whereLike query depending on dataset size.
Can I fork lifo/typeahead-bundle and port it to Laravel?
Not worth it. Removing the Symfony Form coupling means rewriting the only meaningful code in the repository, which is roughly 100 to 200 lines of glue. Prototyping the widget natively in Laravel is faster and gives you maintained, accessible front-end assets. If the pattern repeats, extract it into an internal package such as vendor/laravel-typeahead.
What are the best alternatives to this bundle for Laravel autocomplete?
Use a maintained JavaScript autocomplete library such as Tom Select, Choices.js, or Alpine plus fetch with a Laravel JSON endpoint, and consider Livewire if you want server-driven suggestions. There is no Laravel-native package that mirrors this Symfony bundle directly. If you need a reusable pattern, wrap the component and endpoint in an internal Composer package with a config file and published Blade view.
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.
microsoft/fluentui-system-icons
mmccook/php-json-canonicalization-scheme
middlewares/firewall
qubiqx/montapacking
nyoncode/laravel-package-console
pnscripts/filament-broadquill-lite
pnscripts/laravel-sentfold-lite
vleap/mx-sdk-laravel-internal
twidpay/utils
htetmyathlaing/scout-elasticsearch-driver
artisan-toolbox/front-awesome
ls/client-assistant
users-au/laravel-client
cgv/localized-resource
noith/settings
kda/laravel-package
kda/filament-dynamic-navigation
bypersoft/signbox
pairus/product-data
fayne/laravel-filament-cms-core