Skip to content

Instantly share code, notes, and snippets.

@ZackDeRose
Last active July 16, 2018 23:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ZackDeRose/8d4af3f60cfc2949d82be1445531192e to your computer and use it in GitHub Desktop.
Save ZackDeRose/8d4af3f60cfc2949d82be1445531192e to your computer and use it in GitHub Desktop.
Snippet of table.component.ts for "Angular CDK Tables"
tableDataSource$ = new BehaviorSubject<any[]>([
{
name: 'Hammerer Maccabeus',
types: 'Holy/Fire',
attack: 1,
defense: 1,
speed: 1,
healing: 1,
recovery: 1,
health: 5
},
{
name: 'Ethereal Moodmorph',
types: 'Water/Fire',
attack: 1,
defense: 1,
speed: 1,
healing: 1,
recovery: 1,
health: 5
},
]);
displayedColumns$ = new BehaviorSubject<string[]>([
'name',
'types',
'attack',
'defense',
'speed',
'healing',
'recovery',
'health'
]);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment