generator-jekyllrb icon indicating copy to clipboard operation
generator-jekyllrb copied to clipboard

Custom blockReplacements in usemin task won't work

Open fmontes opened this issue 9 years ago • 0 comments

Hi guys,

Im trying to do this in the usemin task:

usemin: {
  options: {
    assetsDirs: '<%= yeoman.dist %>/index.html',
    blockReplacements: {
      js: function (block) {
          return '<script async src="' + block.dest + '">';
      }
    }
  },
  html: ['<%= yeoman.dist %>/index.html'],
  css: ['<%= yeoman.dist %>/css/**/*.css']
},

Just to add the "async" attr to the script call, but is not working... I tryed everything I can think of... are we running the usemin normally?

Regards...

fmontes avatar Apr 13 '15 03:04 fmontes