Laravel View X-Ray is a package for Laravel 5.6 by Marcel Pociot which enables you to peek into your Laravel views and find out which template matches a specific part of the HTML output.
After installing the package it’s enabled by default in development, and then you can hit
Cmd + Shift + X (
Ctrl + Shift + X on Windows). Note, at the time of writing the View X-Ray package depends on jQuery.
The result is a beautiful visual representation of your view, and it’s easy to understand the view hierarchy at a glance now with X-Ray enabled. You can hide the X-Ray UI by hitting the shortcut again or pressing the esc key.
You can disable X-Ray and exclude views with the following configuration options:
<?php return [ /* * Determines if the Xray package should be enabled. */ 'enabled' => env('XRAY_ENABLED', true), /* * If you want to exclude certain views from being processed by Xray, * you can list them here. Be aware that the check only applies to the * root views that you add here. If these views include other views * themselves, they need to be excluded manually. */ 'excluded' => [ // ], ];
You can install Laravel X-Ray in your Laravel 5.6 applications with the following composer command:
composer require beyondcode/laravel-view-xray --dev
Filed in: Laravel Packages
Join the weekly newsletter and never miss out on new tips, tutorials, and more.
- Lead Front End Developer
- Full-Stack Laravel Developer
- Intermediate PHP Developer (Full Stack | CakePHP | Laravel | Vue | jQuery)
- Senior PHP Developer (Full Stack | CakePHP | Laravel | Vue | jQuery)
- Laravel Developer
Amsterdam (partially remote possible)
- Web Developer (Laravel)
Tweed Heads, New South Wales, AUSTRALIA
Tursa Employment & Training
- Laravel Experts needed-Remote position
Golden Sky ROI