jackfranklin / gulp-load-plugins

Automatically load in gulp plugins
https://github.com/jackfranklin/gulp-load-plugins
MIT License
757 stars 55 forks source link

plugins with dots in the name #65

Closed callumacrae closed 9 years ago

callumacrae commented 9 years ago

I'm trying out a plugin called gulp-buddy.js. What's the best way to load it using gulp-load-plugins?

I don't really want to write plugins['buddy.js'], and changing gulp-load-plugins to replace /\.(\w)/g with the uppercase equivalent would cause collisions (is that an issue?).

I guess the best option I can think of would be to rename it:

gulpLoadPlugins({
  rename: {
    'gulp-buddy.js': 'buddy'
  }
});

Is that the best approach, though?

jackfranklin commented 9 years ago

Ah I hate plugin authors who don't follow the conventions :P (jokes)

Yeah the renaming is probably the best approach here, that's its main use case, catering for plugins that don't follow a general scheme.