Use vertx.js.scriptDir in nameTemplate
Use the module info for generating the correct module import
Use the type info for generating the file name