Conversation
cc89bff to
b43936e
Compare
|
Sorry for the noisy ping, @pi0! As the maintainer of Also, unlike other loaders listed in the index.js file, I can't find another way to supply custom options to jiti, except by setting environment variables. All those process.env calls seem pretty hacky (on top of them not working yet). A simple setup for testing: // package.json
///////////////////////////////
{
"dependencies": {
"gulp": "^5.0.0",
"gulp-cli" "^3.0.0",
"jiti": "^2.4.2"
},
"overrides": {
"gulp-cli": {
"interpret": "git+https://github.com/folliehiyuki/interpret#jiti-loader"
}
}
}
// gulpfile.ts
////////////////////////////////
function defaultTask(cb: any) {
// place code for your default task here
cb();
}
export default defaultTask;Executing |
|
Hi @folliehiyuki can you please clarify what specific options are currently not possible to be set via env variables? (and using loader approach, how to you see alternatives? feel free to create discussion upstream also 👍🏼 ) |
|
Sorry for the late reply! I totally forgot this PR. I believe the problem is that this repo uses CommonJS, while the node register from For CJS, the module can be used with NodeJS like this: |
This PR adds https://github.com/unjs/jiti as a supported loader.