protected function register(
        string $type,
        $name,
        string $source,
        $dependencies,
        $attributes,
        $replaces
    ): void {
        $dependencies = (array) $dependencies;
        $attributes = (array) $attributes;
        $replaces = (array) $replaces;

        if (\is_array($name)) {
            $replaces = \array_merge($name, $replaces);
            $name = '*';
        }

        $this->assets[$type][$name] = [
            'source' => $source,
            'dependencies' => $dependencies,
            'attributes' => $attributes,
            'replaces' => $replaces,
        ];
    }
protected function register(
        string $type,
        $name,
        string $source,
        $dependencies,
        $attributes,
        $replaces
    ): void {
        $dependencies = (array) $dependencies;
        $attributes = (array) $attributes;
        $replaces = (array) $replaces;

        if (\is_array($name)) {
            $replaces = \array_merge($name, $replaces);
            $name = '*';
        }

        $this->assets[$type][$name] = [
            'source' => $source,
            'dependencies' => $dependencies,
            'attributes' => $attributes,
            'replaces' => $replaces,
        ];
    }
protected function register ( string $ type , $ name , string $ source , $ dependencies , $ attributes , $ replaces ) : void { $ dependencies = ( array ) $ dependencies ; $ attributes = ( array ) $ attributes ; $ replaces = ( array ) $ replaces ; if ( \ is_array ( $ name ) ) { $ replaces = \ array_merge ( $ name , $ replaces ) ; $ name = '*' ; } $ this -> assets [ $ type ] [ $ name ] = [ 'source' => $ source , 'dependencies' => $ dependencies , 'attributes' => $ attributes , 'replaces' => $ replaces , ] ; }
Add an asset to the array of registered assets.

@param  string  $type
@param  string|array  $name
@param  string  $source
@param  string|array  $dependencies
@param  string|array  $attributes
@param  string|array  $replaces

@return void
Add an asset to the array of registered assets .