first commit

This commit is contained in:
2026-01-25 18:18:09 +08:00
commit 509312e604
8136 changed files with 2349298 additions and 0 deletions

View File

@ -0,0 +1,13 @@
使用
===========
Yii不会将 bootstrap 合并到PHP代码中因为HTML本身是非常简单的。猛击 [bootstrap 文档页](https://getbootstrap.com/docs/) 查看如何使用 bootstrap. 但是 Yii 还是提供了在框架中更为方便的管理和使用 bootstrap的方式`@app/assets` 路径下的 `AppAsset.php` 文件中,添加如下代码即可:
```php
public $depends = [
'yii\web\YiiAsset',
'yii\bootstrap5\BootstrapAsset', // this line
];
```
通过 Yii 的资源管理器asset manager引入 bootstrap ,可最小化的引入 bootstrap 并在需要时合并自定义资源文件一起使用。