organized the single-page app a little better