vns-agency / front-app-merger
使用 Laravel 合并前端应用
dev-main
2023-11-23 10:55 UTC
Requires
- php: ^8.1|^8.2
- illuminate/support: ^9.0|^10.0
Requires (Dev)
- orchestra/testbench: ^7.0|^8.0
- phpunit/phpunit: ^9.0
This package is auto-updated.
Last update: 2024-09-23 15:20:41 UTC
README
这里应该放置你的描述。尽量限制在一段或两段之内,并提及你支持的PSR,以避免用户和贡献者产生混淆。
安装
您可以通过 composer 安装此包
composer require vns-agency/front-app-merger
使用
// in you AppServiceProvider use FrontAppMerger; public function boot(): void { if ($this->app->runningInConsole()) { FrontAppMerger::registerGitRepo( repository: "git@github.com:vns-agency/test.git", //the blade file path that should be replaced with the newly generated index.html replaceIndexViewPath: resource_path('views/index.blade.php'),// default null //optional parameters and its default values //the front-end app framework projectType: ProjectType::VUE, //currently only supported VUE //package manager Yarn or NPM packageManagerType: PackageManagerType::Yarn, //defult value //disable copying Assets copyAssets: true, //set the front-end app build folder distFolderName: 'dist', //where should the assets move to copyDistFilesTo: public_path() ) //you can chain as many apps as you want ->registerLocalRepo( repository: base_path('mayApp'), //the blade file path that should be replaced with the newly generated index.html replaceIndexViewPath: resource_path('views/index2.blade.php'),// default null ) } }
此包将在每次安装或更新 composer 时自动运行。但是,您也可以使用以下 Artisan 命令手动运行它
//to insatll the fron-end apps
php artisan frontAppMerger
//to clean up the fron-end apps
php artisan frontAppMerger:cleanUp
测试
composer test
变更日志
有关最近更改的更多信息,请参阅 CHANGELOG
贡献
有关详细信息,请参阅 CONTRIBUTING
安全
如果您发现任何与安全相关的问题,请通过电子邮件 test@test.com 联系,而不是使用问题跟踪器。
致谢
许可证
MIT 许可证 (MIT)。有关更多信息,请参阅 许可证文件