I appreciate the check that make:test provides when you are using a starter kit or already have a Pest or a PHPUnit test created in the project, and I think it makes a great addition to Volt, as well.
I always forget to add the --class option when creating a new Volt component for my projects.
This adds a usingClass function to check to see if any Livewire Volt components already exist in the Volt::paths() and if that is identified as a Class component, then it will default to using the Class component stub when the volt:make command is run.
Additionally, I did add a --functional option to the command due to the fact that there are some folks who might want Class & Functional components to exist in the same project. While that can be written manually, I figured it wouldn't hurt to have an additional option, just in case.
I appreciate the check that
make:test
provides when you are using a starter kit or already have a Pest or a PHPUnit test created in the project, and I think it makes a great addition to Volt, as well.I always forget to add the
--class
option when creating a new Volt component for my projects.This adds a
usingClass
function to check to see if any Livewire Volt components already exist in theVolt::paths()
and if that is identified as a Class component, then it will default to using the Class component stub when thevolt:make
command is run.Additionally, I did add a
--functional
option to the command due to the fact that there are some folks who might want Class & Functional components to exist in the same project. While that can be written manually, I figured it wouldn't hurt to have an additional option, just in case.