Skip to content

Conversation

ghost
Copy link

@ghost ghost commented Mar 6, 2016

From within useref custom block handlers I need access to the _basePath variable which gulp-useref uses as vfs.glob base, so that I can push files to the stream and they will be output identically to useref internal blocks.

import: function importer (content, target, options, alternateSearchPath, basePath) {
  //...
  let file = new vinyl({
    base: basePath,
    path: target,
    contents: buffer,
  })
  stream.push(file)
  return `<script src="${target}"></script>`
}

@jonkemp
Copy link
Owner

jonkemp commented Apr 6, 2017

Closing since this is a year old. If you still need it, please submit a new pull request so we can discuss.

@jonkemp jonkemp closed this Apr 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant