Simplify JS for slide-building