Download the PHP package statamic-rad-pack/meilisearch without Composer

On this page you can find all versions of the php package statamic-rad-pack/meilisearch. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package meilisearch

Statamic Meilisearch Driver

This addon provides a Meilisearch search driver for Statamic sites.

Requirements

Installation

Add the following variables to your env file:

The master key is like a password, if you auto-deploy a Meilisearch server they will most likely provide you with keys. On localhost you can make up your own master key then use that to generate your private and public keys. You will need these keys for front-end clients:

Add the new driver to the statamic/search.php config file:

You can optionally add search_api_key which makes it easier to call the key on the frontend javascript code:

You can optionally publish the config file for this package using:

Few words about Document IDs in meilisearch

When you index your Statamic Entries, the driver will always transform the ID. This is required because meilisearch only allows id to be a string containing alphanumeric characters (a-Z, 0-9), hyphens (-) and underscores (_). You can read more about this in the meilisearch documentation

As an Entry, Asset, User or Taxonomy reference is a combination of the type, handle/container and ID separated with a :: (e.g. assets::heros/human01.jpg, categories::cats) this could not be indexed by meilisearch.

As a Workaround, we take care add reference while indexing your entries automatically 🎉.

Internally Statamic will use \Statamic\Facades\Data::find($reference) to resolve the corresponding Statamic Entry, Asset, User or Taxonomy.

Search Settings

Any additional settings you want to define per index can be included in the statamic/search.php config file. The settings will be updated when the index is created.

You may include different types of settings in each index:

Search Pagination

By default we limit the maxTotalHits to 1000000, if you want to modify this or any other pagination settings on the index, specify a pagination key:

Extending

You can extend the drivers functionality (e.g. in order to customize calls to meilisearch) by creating a class that extends StatamicRadPack\meilisearch\meilisearch\Index and instructing Laravel's service container to use it:

Common Errors

413 Request Entity Too Large

You may encounter this bug on Laravel Forge for example, when you try sync the search documents for the first time. To overcome this you need to update the upload size limit in nginx.

Add client_max_body_size to the http section on /etc/nginx/nginx.conf:

Then restart the server, or run sudo service nginx restart.


All versions of meilisearch with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
meilisearch/meilisearch-php Version ^1.0
guzzlehttp/guzzle Version ^7.3
http-interop/http-factory-guzzle Version ^1.0
illuminate/support Version ^9.0|^10.0
statamic/cms Version ^4.41
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package statamic-rad-pack/meilisearch contains the following files

Loading the files please wait ....