Guide for library maintainers

If you're maintaining a PHP or Laravel library this guide provides an overview of how you can prepare your library for best visibility on the Laravel Toolbox.

Packagist.org and Composer provide great documentation on publishing packages, so we won't go into any of that here. Instead, please check out their documentation on the composer.json schema, package naming conventions, versioning and submitting packages. It's always good to have some consistency across the ecosystem, so please keep those community best practices in mind when you publish libraries.

We sync data for all packages indexed on Packagist.org that have at least one currently available release. If all existing versions of a package are removed, we remove it from our database on the next sync.

Referencing your GitHub repository

To make sure we correctly link your package against its source code repository on GitHub (if applicable) and display stats for both on your project you should reference your GitHub repository in your package's composer.json.

You can do so by either setting the homepage or any of the support urls and publishing a new release:

// composer.json

{
  "name": "vendor/widgets",

  // Either set the homepage directly:

  "homepage": "https://github.com/USER/REPO",

  // OR any of these will work (ordered by precedence)

  "support": {
    "source": "https://github.com/USER/REPO",
    "issues": "https://github.com/USER/REPO/issues"
  }
}

Once this data becomes available through the Packagist.org API and gets synced by the Laravel Toolbox we'll pick up the GitHub repository reference and start displaying your library's GitHub metrics as well.

To keep things orderly please remember to also drop outdated links when you publish a forked version of a library.

Adding your library to a category

To add your library to an existing or new category please send a pull request against our catalog repository.