src/console/DumpController.php
public function actionComponent($name = null)
    {
        $data = Yii::$app->getComponents();
        if ($name) {
            if (empty($data[$name])) {
                Yii::error("'$name' not defined");

                return;
            }
            $data = [$name => $data[$name]];
        }
        echo Yaml::dump($data, 4);
    }
public function actionComponent($name = null)
    {
        $data = Yii::$app->getComponents();
        if ($name) {
            if (empty($data[$name])) {
                Yii::error("'$name' not defined");

                return;
            }
            $data = [$name => $data[$name]];
        }
        echo Yaml::dump($data, 4);
    }
public function actionComponent ( $ name = null ) { $ data = Yii :: $ app -> getComponents ( ) ; if ( $ name ) { if ( empty ( $ data [ $ name ] ) ) { Yii :: error ( "'$name' not defined" ) ; return ; } $ data = [ $ name => $ data [ $ name ] ] ; } echo Yaml :: dump ( $ data , 4 ) ; }
Dump defined components.
@param string $name component name
Dump defined components .