PHPackages                             beyondcode/laravel-view-xray - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Debugging &amp; Profiling](/categories/debugging)
4. /
5. beyondcode/laravel-view-xray

AbandonedArchivedLibrary[Debugging &amp; Profiling](/categories/debugging)

beyondcode/laravel-view-xray
============================

Take a look into your Laravel views.

1.4.0(5y ago)569108.8k25[1 PRs](https://github.com/beyondcode/laravel-view-xray/pulls)1MITPHPPHP ^7.1

Since Jul 19Pushed 3y ago7 watchersCompare

[ Source](https://github.com/beyondcode/laravel-view-xray)[ Packagist](https://packagist.org/packages/beyondcode/laravel-view-xray)[ Docs](https://github.com/beyondcode/laravel-view-xray)[ RSS](/packages/beyondcode-laravel-view-xray/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (8)Dependencies (4)Versions (9)Used By (1)

Xray - Take a look into your Laravel views
==========================================

[](#xray---take-a-look-into-your-laravel-views)

[![Latest Version on Packagist](https://camo.githubusercontent.com/1c368b132e6af9b4c7ea176dbf681ee7ee7929e1f3037804eaa40d01370e338d/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6265796f6e64636f64652f6c61726176656c2d766965772d787261792e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/beyondcode/laravel-view-xray)[![Build Status](https://camo.githubusercontent.com/de19c9202f5f94c3cc1c732d297cb05302b1ffc6ef58b00fd305448ec615b5f3/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f6265796f6e64636f64652f6c61726176656c2d766965772d787261792f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/beyondcode/laravel-view-xray)[![Quality Score](https://camo.githubusercontent.com/061acf68fe953e99e851a185d03987dfa36c9fe6b561ba13d4da27654926853b/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f6265796f6e64636f64652f6c61726176656c2d766965772d787261792e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/beyondcode/laravel-view-xray)[![Total Downloads](https://camo.githubusercontent.com/302aefe51e21fa65d68a54cf766f4b36fb33cedb7612877962714aa28151fb82/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6265796f6e64636f64652f6c61726176656c2d766965772d787261792e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/beyondcode/laravel-view-xray)

When your Laravel project grows, so do the Laravel views. Sometimes it might be hard to figure out, which part of the output HTML was rendered using which template. With this package, you can take a peek into your Laravel views and find out which template is responsible for which part of the output HTML.

[![Example output](https://camo.githubusercontent.com/4cfb68f777b0677ffc245de04d88f85c7ce0b93ddc65716e9561025ab7ae2f76/68747470733a2f2f6265796f6e64636f2e64652f6769746875622f787261792f787261792e706e67)](https://camo.githubusercontent.com/4cfb68f777b0677ffc245de04d88f85c7ce0b93ddc65716e9561025ab7ae2f76/68747470733a2f2f6265796f6e64636f2e64652f6769746875622f787261792f787261792e706e67)

Installation
------------

[](#installation)

You can install the package via composer:

```
composer require beyondcode/laravel-view-xray --dev
```

The package is enabled by default - so all you need to do is visit your application in the browser and hit the Xray shortcut.

- Windows: CTRL + Shift + X
- OSX: CMD + Shift + X

This toggles the Xray view, where you can see which view (and optionally section) rendered the visual output.

Disabling Xray
--------------

[](#disabling-xray)

You can disable Xray by setting an environment variable called `XRAY_ENABLED` to `false`.

Excluding views
---------------

[](#excluding-views)

If you want to exclude certain views from being processed by Xray, you can do this by adding them to the configuration file.

Publish the configuration file using:

```
php artisan vendor:publish --provider=BeyondCode\\ViewXray\\ViewXrayServiceProvider
```

This will publish a file called `xray.php` in your `config` folder.

This is the content of the configuration file:

```
