Overriding bootstrap asset but it is being included twice

Hi folks,

On my config file, I have overridden the bootstrap asset as I am modifying and recompiling my own version of it. Here is the code in my frontend config: -

        'assetManager' => [

            'bundles' => [

                'yii\bootstrap\BootstrapAsset' => [

                    'sourcePath' => '@frontend/assets/bootstrap/dist/',

                    'css' => ['css/bootstrap.css']



            'appendTimestamp' => TRUE,


However, when I do this, the Bootstrap asset is being published twice to the frontend/web/assets path - it is publishing the newly compiled version in @frontend/assets/bootstrap/dist/ as well as the original version.

Could someone show me what I am doing wrong here pls?


did you checked your loading assert file’s dependence.

For anyone who still needs a fix for this, see here: -