-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New loader parameter syntax, loader support. #12
New loader parameter syntax, loader support. #12
Conversation
…rt for specifying loaders for requires, resolves issue deepsweet#1.
thanks! you are a maintainer with collaborator's access now. let me know when you'll be ready to publish something to NPM. 👍 |
Hope this gets merged soon :) |
index.js
Outdated
if (typeof query[filePath] === 'object') { | ||
var fileConfig = query[filePath]; | ||
var loaderStringForFile = fileConfig.loaders || ''; | ||
loadersForFile = loaderStringForFile.replace(/\*/g, '!') + '!'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if you don't conditionally apply this, the loader will prefix all imports with !
voiding your webpack config's rules. (I've merged your branch into my fork and fixed it)
so, what about maintaining this? |
i would be happy to, if that question was directed at me. |
Thanks @jsg2021, incorporated that conditional. @deepsweet sorry for the delay; I emailed you a little while ago -- wasn't sure if you wanted to review/approve/etc. or if I should just run with it. Anyway, ready to publish to NPM but have never done so before. How do I publish it? |
@gannondigital awesome. to make this compatible with webpack2, you should update the peer deps, and check out my fork. i've already done the work. |
@gannondigital https://docs.npmjs.com/getting-started/publishing-npm-packages + http://semver.org/ write your NPM username here when you are ready to try, I'll give you an access. |
@deepsweet Hey, ready to publish stuff -- my NPM username is |
done |
Hey, I'd be happy to maintain this project. I've been using a fork of
baggage-loader
at work for a while, with a bunch of customizations; I think it's one of the most useful loaders out there.This pull establishes a new syntax for the loader's query params, to support greater configurability in the future. Seemed like it was needed, based on the open issues (and my own use cases). The old syntax is still supported, but not for new functionality.
Added support for specifying loaders, per-
require
, resolving issue #1. Because of the change in syntax, I bumped the version to 1.0.0 and updated the README (also tried to make it a little clearer).