Jetstream基本使用
# 安装
composer require laravel/jetstream
1
# 基于 Livewire
php artisan jetstream:install livewire
php artisan jetstream:install livewire --teams
1
2
3
2
3
# 基于 Inertia
php artisan jetstream:install inertia
php artisan jetstream:install inertia --teams
1
2
3
2
3
# 最后
安装 JetStream 后,安装构件 npm 依赖,并迁移数据库
npm install
npm run dev
php artisan migrate
1
2
3
2
3
# 修改应用 LOGO
# Livewire
先发布 Livewire 技术栈的 Blade 组件:
php artisan vendor:publish --tag=jetstream-views
1
接下来,应该定制位于 resources/views/vendor/jetstream/components/application-logo.blade.php、 resources/views/vendor/jetstream/components/authentication-card-logo.blade.php 和 resources/views/vendor/jetstream/components/application-mark.blade.php 组件中的 svg。
# Inertia
果使用 Inertia 技术栈,应该自定义位于 resources/js/Jetstream/AuthenticationCardLogo.vue、 resources/js/Jetstream/ApplicationLogo.vue 和 resources/js/Jetstream/ApplicationMark.vue 中的 svg。
然后重新构建应用:
npm run dev
1
上次更新: 2023/09/22, 16:54:32