Open vnenkpet opened 9 years ago
Yes this is good idea, but we need to reproduce frontend navbar on pure css, fortunately he is very simple :)
Hello. I am thinking about the separation of easyii-navbar style and bootstrap style. It is pretty simple to implement, but still have some questions:
Подскажите как отключается bootsrap для форнтенда ? Летит вся вся верстка из-за него
@lial Бандлы можно переназначить в конфиге
'components' => [
'assetManager' => [
'class' => 'yii\web\AssetManager',
'linkAssets' => true,
'appendTimestamp' => YII_ENV_DEV,
'bundles' => [
'yii\bootstrap\BootstrapAsset' => [
'sourcePath' => null, 'css' => [],
],
'yii\bootstrap\BootstrapPluginAsset' => [
'sourcePath' => null, 'js' => [],
],
'yii\jui\JuiAsset' => [
'sourcePath' => null, 'css' => [], 'js' => [],
],
],
],
Я спрашивал как отключать их для фронта только, то что указали вы есть в манах Yii и оно проблему не решает, ибо отключает их как для фронта так и для бэкенда, чуствуете разницу ?
Тогда внимательнее прочитайте маны по yii\web\AssetBundle
public $depends = [
'yii\web\JqueryAsset',
//'yii\bootstrap\BootstrapAsset',
];
Данный код уберет из подгрузки зависимость bootstrap.css. Я правильно прочувствовал разницу?
Sometimes loading the bootstrap css and js files can break your layout if your front-end doesn't use bootstrap at all. Can we create a new Asset that only affects easyii-navbar and is loaded alone instead of the Bootstrap asset when not in the /admin area?