Laravel Scout extension that allows to use meilisearch advanced features as well as has an extended collection driver for testing purposes.
alejandroakbal/laravel-scout-advanced-meilisearch is a Laravel package for laravel scout extension that allows to use meilisearch advanced features as well as has an extended collection driver for testing purposes..
It currently has 0 GitHub stars and 20 downloads on Packagist (latest version 1.0.2).
Install it with composer require alejandroakbal/laravel-scout-advanced-meilisearch.
Discover more Laravel packages by alejandroakbal
or browse all Laravel packages to compare alternatives.
Last updated
Added next changes to the basic query builder:
where('column', '<=', $value) - extended where, which supports 3 optional parameters for comparison.
Two parameters are also allowed.where(Clusure $query) - where can take a closure as the first parameter in order to group queries (the same
for orWhere)whereBetween('column', [$value1, $value2])whereNotIn('column', [$value1, $value2, $value3])orWhere, orWhereIn, etcThe drivers are compatible with the new scout builder.
Uses all the advantages of meilisearch for comparison the results, searching in indexed arrays.
Also fixes an issue with the calculation of the total number of values.
(The current implementation requests the entire dataset in case scout builder has ->query() method used)
The driver imitates how meilisearch work and completely relies on collections. It should be used only for tests as the whole searchable models data is in memory. The driver allows testing filtering and sorting as well as Extended scout builder features.
config/scout.php set 'driver' to meilisearch_advanced or collection_advanced (for tests)Use PHP with Docker
docker run --rm \
-u "$(id -u):$(id -g)" \
-v "$(pwd):/var/www/html" \
-w /var/www/html \
laravelsail/php82-composer:latest \
composer install
docker run --rm \
-u "$(id -u):$(id -g)" \
-v "$(pwd):/var/www/html" \
-w /var/www/html \
laravelsail/php82-composer:latest \
composer test
You can publish a package version with:
git tag -a 1.0.0 -m "First release"
git push --tags