Laravel Vue Make

Create Vue single file components using Artisan. Laravel 8, 7 and 6.


I scaffold files using Artisan a lot. Having a command available to all developers working on a particular codebase helps keep things consistent.


Install in your Laravel directory via Composer.

% cd /path/to/laravel/project
% composer require --dev fsac/laravel-vue-make


Generate a Vue component in the file MyComponent.vue under resources/js/components.

% php artisan make:vue MyComponent

You may also include subdirectories. The following will create a component in the foo/bar subdirectory of resources/js/components.

% php artisan make:vue foo/bar/MyComponent

Customise Stubs

Optional. If you'd like to customise the default templates you may publish them to the stubs directory. For example you may wish to add a <style> tag.

% php artisan vendor:publish --tag vue-stub


Laravel Vue Make is open-sourced software licensed under the MIT license.