There's a validation for generator.actions while running runGeneratorActions.
I'm using vm to load plopfile and programmatically register it to node plop api instance.
But the instanceof Array would fail when the actions come from vm script. Maybe node-plop should use Array.isArray instead.
const vm = require('vm')
const s = new vm.Script(`[]`).runInNewContext()
s instanceof Array // false
Array.isArray(s) // true
There's a validation for
generator.actions
while runningrunGeneratorActions
.I'm using
vm
to load plopfile and programmatically register it to node plop api instance. But theinstanceof Array
would fail when the actions come fromvm
script. Maybenode-plop
should useArray.isArray
instead.Related to https://github.com/nodejs/node/issues/37921