Move helper mthods into classes
Re-architectured JavaScript