You are here

public function Ng2Block::attachFramework in Decoupled Blocks 8

Attaches the framework required by the component.

Parameters

array $component: The component definition.

Return value

array Array of attachments.

Overrides PdbBlock::attachFramework

File

modules/pdb_ng2/src/Plugin/Block/Ng2Block.php, line 35

Class

Ng2Block
Exposes an Angular 2 component as a block.

Namespace

Drupal\pdb_ng2\Plugin\Block

Code

public function attachFramework(array $component) {
  $attached = [];
  $attached['drupalSettings']['pdb']['ng2']['global_injectables'] = [];
  return $attached;
}