import { Component } from "@angular/core" ; import { ICellRendererAngularComp } from "ag-grid-angular/main" ; @ Component ( { selector : 'cube-cell' , template : `{{valueCubed()}}` } ) export class CubeComponent implements ICellRendererAngularComp { private params : any ; private cubed : number ; agInit ( params ) { this . params = params ; this . cubed = this . params . data . value * this . params . data . value * this . params . data . value ; } refresh ( params ) { this . params = params ; this . cubed = this . params . data . value * this . params . data . value * this . params . data . value ; return true ; } public valueCubed ( ) { return this . cubed ; } }