frontend-maven-plugin
frontend-maven-plugin copied to clipboard
New Mojo to run node with arbitrary arguments
New Mojo to execute arbitrary node commands
As explained in issue #996 I need a new Mojo to run node command with arbitrary parameters
Tests and Documentation
README.md contains an example to use NodeMojo plugin.
A few people have asked for this feature, but perhaps not many enough. What people usually do is npm run your-script from Maven, and then in package.json add "your-script": "node something.js" inside the scripts block. You then get the additional benefit of being able to do npm run your-script directly from the command line (without Maven) which can be convenient if your command is somewhat complex (node some/kind/of/script.js --foo bar ./bla --etc).
Yes, that's a solution. In my situation, at this point, I do not have anymore need of npm, so adding a package.json in my maven project is not very useful.
But yes, it's a good workaround. Thanks.