TypeScript

by Aggre _--

HTML

<div id="app"></div>

CSS

body {
  background: #20262E;
  padding: 20px;
  font-family: Helvetica;
}

#app {
  background: #fff;
  border-radius: 4px;
  padding: 20px;
  transition: all 0.2s;
  text-align: center;
}

TypeScript

type Person = {
	name: string,
	birthday: Date
}

const persons: Person[] = [
	{
		name: 'Alice',
		birthday: new Date('1999-02-03T11:22:33Z')
	},
	{
		name: 'Bob',
		birthday: new Date('2012-03-32T03:21:43Z')
	},
	{
		name: 'Alice',
		birthday: new Date('2012-03-32T03:21:43Z')
	}
]

document.querySelector("#app").innerHTML = greeter(user);