This change allows Spin to be required as a Common JS module without having a DOM available. It also consolidates the initialization code into one place.
This is crucial for using Spin in isomorphic apps. Nothing should be affected other than this ability being added.
I wasn't sure why the stylesheet initialization code was in a IEFE, so I left it as is.
Allow spin to be required on server.