import {ui, Button, TextView} from 'tabris';

let button = new Button({
  centerX: 0, top: 100,
  text: 'Show Message'
}).appendTo(ui.contentView);

let textView = new TextView({
  centerX: 0, top: [button, 50],
  font: '24px'
}).appendTo(ui.contentView);

button.on('select', () => textView.text = 'Tabris.js rocks!');

import {ui, Button, TextView} from 'tabris';

let button = new Button({
  centerX: 0, top: 100,
  text: 'Show Message'
}).appendTo(ui.contentView);

let textView = new TextView({
  centerX: 0, top: [button, 50],
  font: '24px'
}).appendTo(ui.contentView);

button.on({select: () => textView.text = 'Tabris.js rocks!'});

Use object to attach event listener in TypeScript template
Use object to attach event listener in TypeScript template

Change-Id: Ica58ecd12a4952e27db7a8fe8fea75e305c64f03
