underscore-template-loader icon indicating copy to clipboard operation
underscore-template-loader copied to clipboard

underscore-template-loader in custom jest transformer

Open dhaval-lila opened this issue 6 years ago • 1 comments

I am writing custom jest transfomer for ejs templates something like this

const temp = require('underscore-template-loader');
module.exports = {
  process(src) {
   return temp(src);
  },
};

i am getting error something like this TypeError: this.async is not a function . what is the correct way to write transformer using underscore-template-loader?

dhaval-lila avatar Jun 18 '18 13:06 dhaval-lila

@dhaval-lila have you been able to figure out the cause for this issue or a workaround? I am currently running into the same problem as well.

khaled-nabil avatar Sep 11 '19 07:09 khaled-nabil