Github: https://github.com/bigrocs/laravelvue
LaravelVUE uses front-end and back-end separation technology. The front-end uses VUE and the back-end uses the CMS system of the PHP framework laravel.
The backend automatically defines the front-end page display content through JSON data.
Below we take the development version as an example to describe the installation of LaravelVUE.
First we need to download the LaravelVUE project and extract it to a local folder:
1. Then execute the composer command to install laravel dependencies
composer install
2. Rename .env.example to .env. Execute the following command and claim the laravel key
php -r "file_exists('.env') || copy('.env.example', '.env');"
php artisan key:generate
3. Set the database configuration and modify the following code in the .env file
DB_DATABASE=homestead(数据库名称)
DB_USERNAME=homestead(数据库账号)
DB_PASSWORD=secret (数据库密码)
4. Next we do database migration and fill data
php artisan migrate
php artisan db:seed
php artisan passport:install
5. Since installing the front-end VUE compilation
npm install
6. Compile front-end resources
npm run dev
7. Compile front-end resources and turn on BrowserSync (development mode)
npm run watch
Backend: http://localhost/admin Account: admin Password: admin888
Modify the code below the webpack.mix.js file
host: 'laravelvue.dev',
proxy: 'laravelvue.dev',
And fill in the corresponding local resolution in the hosts file
127.0.0.1 laravelvue.dev
Developer mode access address: http://laravelvue:3000/admin