Tinkerwell 4 is out now! See what's new or buy now.
Tinkerwell background image
Tinkerwell Logo Tinkerwell

Detail Dive
#

Detail Dive is a brand new feature of Tinkerwell 4 that provides structured output for your dump, var_dump and echo statements. It also allows you to switch between multiple views of the output based on the type of data you are working with.

Enabling Detail Dive
#

You may switch between the traditional "CLI" output (like php artisan tinker) and the new Detail Dive output by clicking the "Detail Dive" button in the top right corner of the Tinkerwell window.

Detail Dive Button

Basic Usage
#

When Detail Dive is enabled, you may use the dump, var_dump and echo statements as usual. Instead of the traditional, rather unstructured output, Detail Dive will provide individual cards for each output/dumped value.

Detail Dive Output

If the output is a nested array or object, the output will be collapsed by default. You may click on the arrow icons on each collapsed line to expand the output. Additionally, you may configure Detail Dive to automatically expand all output by default in the Tinkerwell settings.

Open project files
#

If you are using dd or dump in your project code and trigger a method or function that runs that code, Tinkerwell will show a card for these as well. You can also set a preferred editor in the settings and open the file from the card directly by clicking on the file path.

Currently, VSCode, PhpStorm and Sublime Text are supported for Windows; macOS also supports TextMate and Nova. Please note that for Sublime Text, the sublime_url helper has to be installed on macOS and subl-protocol on Windows. For PhpStorm on Windows, please install the PhpStorm protocol handler.

Inspect SQL Queries
#

When in Detail Dive mode, you may toggle the "SQL" button in the top right corner of the Tinkerwell window to inspect SQL queries that were executed during your code execution.

Detail Dive SQL

Please note that this feature is currently only available for Laravel and WordPress projects, and it does not work with MS SQL Server.

Table View
#

When the output of your code is a collection or a nested array, a "table" icon will appear in the top right corner of the output card.

Detail Dive Table Icon

Clicking this icon will open a modal window with a table view of the output.

Detail Dive Table View

You can also save the given data as CSV - this is especially useful when building more complex Eloquent queries that you want to access as CSV data. Since Tinkerwell executes the code within your application context (locally or via SSH) you can make use of all your Eloquent model relations or scopes.

Copying data from the table view
#

When working with the table view, it can be very useful to be able to copy a specific row as either JSON data or even as a PHP array. You may right-click on any row in the table view, which will open up a context menu.

This context menu allows you to choose how you want to copy the given row.

Here's the example output of copying one row as a PHP array:

$array = [
'name' => 'Marcel',
'role' => 'Creative Genius',
];

Graph View
#

When the output of your code is a nested array or object, an "eye" icon will appear in the top right corner of the output card.

Detail Dive Graph Icon

Clicking this icon will open a modal window with a graph view of the output. This graph view allows you to inspect the structure of the output in a more visual way. You may click on the nodes to expand them and see their children.

Detail Dive Graph View

HTML View
#

When dumping a Laravel view or mailable, you may click the "eye" icon in the top right corner of the output card to open a modal window with a rendered HTML view of the output.

This allows you to quickly inspect the rendered HTML of your views and mailables.

While the HTML preview is open, you may re-run your code via the configured shortcut (default: Cmd/Ctrl + R) to see the updated HTML output.

Detail Dive HTML View