Laravel Web Tinker
Published on by Paul Redmond
Laravel Web Tinker is a package by @spatie_be for running the Laravel Tinker REPL (read-eval-print loop) environment in your browser:
Artisan’s tinker command is a great way to tinker with your application in the terminal. Unfortunately running a few lines of code, making edits, and copy/pasting code can be bothersome. Wouldn’t it be great to tinker in the browser?
This package will add a route to your application where you can tinker to your heart’s content.
Admittedly I was a little skeptical at first; however, one of my favorite features of using this tool is the ease at writing multiple lines of code before executing (which can be painful in the CLI):
Using this tool enables you to iterate on the code by hitting Command + Enter to run tinker, getting the feedback, and continue to edit the code further.
As mentioned in the readme, it’s essential to understand that you shouldn’t install or run this package in a production environment, or any environment handling real-world data.
You can learn more about this package, get full installation instructions, and view the source code on GitHub at spatie/laravel-web-tinker.