First stab at developing reusable UI components in JavaScript