Skip to content

Instantly share code, notes, and snippets.

@bewithdhanu
Last active April 26, 2023 13:09
Show Gist options
  • Save bewithdhanu/eee119fe1ee30be62f4e54d44ffe1ab8 to your computer and use it in GitHub Desktop.
Save bewithdhanu/eee119fe1ee30be62f4e54d44ffe1ab8 to your computer and use it in GitHub Desktop.
Installation Guide for telescope in Laravel

Installation Guide for telescope in laravel

Telescope is a powerful debugging tool for Laravel applications. It provides a beautiful interface for debugging and monitoring your application in real-time. With Telescope, you can easily find performance bottlenecks, track down errors, and debug your code more efficiently.

  1. Install Telescope using Composer:

    composer require laravel/telescope

    This command installs Telescope and its dependencies using Composer, a package manager for PHP.

  2. Install Telescope using the artisan command:

    php artisan telescope:install

    This command installs Telescope's database tables and configuration files. It also publishes Telescope's assets, such as its JavaScript and CSS files, to your application's public directory.

  3. Migrate the Telescope tables to your database:

    php artisan migrate

    This command runs the database migrations for Telescope, which creates the necessary tables in your database for storing Telescope's data.

  4. Access Telescope by visiting [your_domain.com]/telescope in your web browser.

    This step assumes that you have already set up your Laravel application and have a web server running. Once you have Telescope installed and your database configured, you can access it by visiting MAIN_DOMAIN/telescope in your web browser. This will bring up the Telescope dashboard, where you can view your application's requests, exceptions, and other debugging information.

  5. (Optional) If you want to add middleware for authentication, you can do so by modifying the middleware array in the config/telescope.php file. Simply add the name of your middleware class to the array.

    This step is optional and only applies if you want to add middleware to Telescope for authentication purposes. If you have a custom middleware class that you want to use with Telescope, you can add it to the middleware array in the config/telescope.php file. This will ensure that your middleware is applied to Telescope's routes.

Uninstall telescope

You just need to remove th composer library

composer remove laravel/telescope
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment