iboot/core

这是iboot项目的核心包


README

描述。

这是一个核心包管理工具

为Laravel 10添加配置

文件 package.json


{
    "private": true,
    "scripts": {
        "dev": "npm run development",
        "development": "mix",
        "watch": "mix watch",
        "watch-poll": "mix watch -- --watch-options-poll=1000",
        "hot": "mix watch --hot",
        "prod": "npm run production",
        "production": "mix --production"
    },
    "devDependencies": {
        "axios": "^1.1.2",
        "laravel-mix": "^6.0.49",
        "popper.js": "^1.16.1"
    },
    "dependencies": {
        "autoprefixer": "10.4.5",
        "glob": "^10.3.10"
    }
}

创建新项目并添加文件 webpack.mix.js

const mix = require('laravel-mix');
const glob = require('glob');
const path = require('path');

/*
 |--------------------------------------------------------------------------
 | Mix Asset Management
 |--------------------------------------------------------------------------
 |
 | Mix provides a clean, fluent API for defining some Webpack build steps
 | for your Laravel applications. By default, we are compiling the CSS
 | file for the application as well as bundling up all the JS files.
 |
 */

mix.options({
  processCssUrls: false,
  clearConsole: true,
  terser: {
    extractComments: false,
  }
})

// Run all webpack.mix.js in app
glob.sync(path.resolve(__dirname) + '/vendor/iboot/**/webpack.mix.js').forEach(item => require(item))
glob.sync(path.resolve(__dirname) + '/packages/**/webpack.mix.js').forEach(item => require(item))

如何安装?

composer require iboot/core

运行环境

php artisan core:environment
  • 更改您的config/auth.php文件
'providers' => [
    'users' => [
        'driver' => 'eloquent',
        'model' => \IBoot\Core\App\Models\User::class,
    ],
];
  • 安装 node_modules
npm install

运行演示

php artisan ser
npm run watch

https://:8000/admin

Email: admin@icitech.net
Password: password