Use 'window' check to determine Node/phantom env.