[![enter image description here](https://i.stack.imgur.com/PKlCN.png)](https://i.stack.imgur.com/PKlCN.png)I am using yii2 framework since last few weeks. But now I am getting some issues with composer itself.

Just for info, I am using ubuntu 14.04

When I require some new package / extensions, I do the composer add by using composer require command. But I noticed that sometimes it's removing few of the existing packages from my vendor and project.

I tried with following commands.

```
composer require dmstr/yii2-adminlte-asset "*"

composer require 2amigos/yii2-file-upload-widget:~1.0

```

And also tried with some googling.

<http://www.yiiframework.com/wiki/672/install-specific-yii2-vendor-extension-dependency-without-updating-other-packages/>

But it's not working.

Is there a way to add a new package / extension into your existing yii 2 project without removing existing packages or without any composer update command?

**Composer.json**

```
{
    "name": "sganz/yii2-advanced-api-template",
    "description": "Improved Yii 2 Advanced Application Template By Sandy Ganz, Original by Nenad Zivkovic",
    "keywords": ["yii2", "framework", "advanced", "improved", "application template", "nenad", "sganz"],
    "type": "project",
    "license": "BSD-3-Clause",
    "support": {
        "tutorial": "http://www.freetuts.org/tutorial/view?id=6",
        "source": "https://github.com/sganz/yii2-advanced-api-template.git"
    },
    "minimum-stability": "dev",
    "prefer-stable":true,
    "require": {
        "php": ">=5.4.0",
        "yiisoft/yii2": "*",
        "yiisoft/yii2-bootstrap": "*",
        "yiisoft/yii2-swiftmailer": "*",
        "nenad/yii2-password-strength": "*",
        "mihaildev/yii2-ckeditor": "*",
        "dmstr/yii2-adminlte-asset": "*"
    },
    "require-dev": {
        "yiisoft/yii2-codeception": "*",
        "yiisoft/yii2-debug": "*",
        "yiisoft/yii2-gii": "*",
        "yiisoft/yii2-faker": "*",
        "codeception/specify": "*",
        "codeception/verify": "*"
    },
    "config": {
        "vendor-dir": "protected/vendor",
        "process-timeout": 1800
    },
    "extra": {
        "asset-installer-paths": {
            "npm-asset-library": "protected/vendor/npm",
            "bower-asset-library": "protected/vendor/bower"
        }
    }
}

```

Any help on this would be greatly appreciated.
['https://Stackoverflow.com/questions/39099218', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/6608101/']
Try

```
composer --no-update require dmstr/yii2-adminlte-asset:*

```
1. Your problem is, that the packages which are removed are NOT in the `require` nor in `require-dev` section of your `composer.json`. So I assume that the removed packages formerly were (sub-)required by any of the other packages in your `composer.json` and with the newer version of these packages this requirement was dropped. This should be a normal behavior and should be no problem for your project!
2. As @Bizley already showed you can add a requirement without updating the old ones:

```
composer --no-update require dmstr/yii2-adminlte-asset:*

```