lib/resolver.js
function readAsync(resource) {
  return fs.readFile(resource).then(body => {
    const mimeType = mime.getType(resource);

    debug('Fetched:', resource);

    return Bluebird.resolve({
      contents: body,
      path: resource,
      mime: mimeType
    });
  });
}
function readAsync(resource) {
  return fs.readFile(resource).then(body => {
    const mimeType = mime.getType(resource);

    debug('Fetched:', resource);

    return Bluebird.resolve({
      contents: body,
      path: resource,
      mime: mimeType
    });
  });
}
function readAsync ( resource ) { return fs . readFile ( resource ) . then ( body => { const mimeType = mime . getType ( resource ) ; debug ( 'Fetched:' , resource ) ; return Bluebird . resolve ( { contents : body , path : resource , mime : mimeType } ) ; } ) ; }
Get local resource
@param {string} resource Resource to be fetched
@returns {Promise} Promise
Get local resource