If you're using Cscript to execute JavaScript on Windows...

This doesn't work:


This does:


This is not fun. It's one thing to learn idiosyncratic javascript engines in different browsers on different plats, but another when you're dealing with engines that just support whatever the heck they wanna. (He says without having checked the ECSAscript standard...)

I mean, Powershell is idiosyncratic like mad, but it's solidly idiosyncratic in consistent ways. Cscript might not quite understand that JavaScript is understood outside of Cscript context... (Why not just use Node? I would, but this is code we had delivered from YA Contractor, and it's Windows-objected-up all over the place.)

Labels: , ,