Skip to content

Instantly share code, notes, and snippets.

@deffjay
Last active July 18, 2020 07:13
Show Gist options
  • Save deffjay/917d319570f9c448492051a534e9046f to your computer and use it in GitHub Desktop.
Save deffjay/917d319570f9c448492051a534e9046f to your computer and use it in GitHub Desktop.
Install clockwork profiling library for Laravel > 5.5

Install the Clockwork library via Composer.

$ composer require itsgoingd/clockwork --dev

If you are running the latest Laravel version, congratulations you are done!

By default, Clockwork will only be available in debug mode, you can change this and other settings in the configuration file. Use the vendor:publish Artisan command to publish the configuration file into your config directory.

If you prefer to use a Facade, add following to your config/app.php:

'aliases' => [
	...
	'Clockwork' => Clockwork\Support\Laravel\Facade::class,
]

Note: If you are using Laravel route cache, you will need to refresh it using the route:cache Artisan command.

Usage

To interact with the data collected by Clockwork, you will need to

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment