Fixed some incompatibilities and optimized the classList polyfill

Fixes -
- Any classList modification of an element with no className would prepend a whitespace to the beginning of the className.

Optimization -
- Cached Array.prototype instead of creating a new array literal for every method needed.