JS Refactor

tried to implement scroller binder through setInterval Method, but
onscroll is smoother than through interval;
Also used Factory pattern to obtain DRY Code.