You are here

public function ScssCompilerAlterStorage::set in SCSS/Less Compiler 8

Set data by module/theme name.

Parameters

array $values: Array with data.

string $namespace: Module/theme name. By default global scope.

File

src/ScssCompilerAlterStorage.php, line 46

Class

ScssCompilerAlterStorage
Collects alter data.

Namespace

Drupal\scss_compiler

Code

public function set(array $values, $namespace = '_global') {
  if (!isset($this->storage['namespace'][$namespace])) {
    $this->storage['namespace'][$namespace] = [];
  }
  $this->storage['namespace'][$namespace] = array_merge($this->storage['namespace'][$namespace], $values);
}