replace duck-typing checks w/ process.browser checks.