Cross environment next-tick polyfill