Refactor environ to npm-module

\cc @arikon @scff @tadatuta @veged