Skip to content

refactor(loader): v1.0.0 #642

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

Merged
merged 1 commit into from
Jan 4, 2018
Merged

refactor(loader): v1.0.0 #642

merged 1 commit into from
Jan 4, 2018

Conversation

michael-ciniawsky
Copy link
Member

@michael-ciniawsky michael-ciniawsky commented Dec 10, 2017

⚠️ DO NOT MERGE ⚠️

Noteable Changes

Features

url (options.url)

file.css

.selector {
  background-url: url('path/to/file.png');
}

module.js

import CSS__URL__0 from 'path/to/file.png';

export default `.selector { background-url: url(${CSS__URL__0}); }`

import (options.import)

file.css

@import './path/to/import.css';

...css

module.js

import CSS__IMPORT__0 from 'path/to/import.css';

export default `${css}`

sourceMap (options.sourceMap)

  • enable/disable source maps

BREAKING CHANGES

root (options.root)

  • Removed

alias (options.alias)

  • Removed (needs triage)

modules (options.modules|options.localIdentName|options.camelCase)

  • Removed (will be a separate plugin usable via postcss-loader)

minimize (options.minimize)

  • Removed

importLoaders (options.importLoaders)

  • Removed (not needed anymore webpack >= v2.0.0)

Issues

Coming soon...

TODO

  • port changes from src/lib/plugins/url to postcss-icss-url (PR #?)
    • add plugin option to filter urls {Regex|Function}
  • port changes from src/lib/plugins/import to postcss-icss-import (PR #?)
    • add plugin option to filter urls {Regex|Function}
  • update CSS runtime (src/lib/runtime.js)

Status

Name Status
Default
CSS URLs
CSS Imports
CSS Runtime
Options - url ⚠️
Options - import ⚠️
Options - sourceMap

Blocked by

Coming soon...

ℹ️ @webpack-contrib/org-maintainers If the direction of this PR is basically fine, it may be better to merge this as the MVP into next and continue adding the missing features via separate PR's to reduce the boilerplate and legacy noise for review

@michael-ciniawsky
Copy link
Member Author

@d3viant0ne Could you please enable the CI stuff here :) ?

@michael-ciniawsky michael-ciniawsky changed the title [WIP] refactor: apply webpack-defaults [WIP] refactor(loader): v1.0.0 Dec 10, 2017
@anru
Copy link

anru commented Dec 11, 2017

modules (options.modules|options.localIdentName|options.camelCase)
Removed (will be a separate plugin usable via postcss-loader)

This will be great!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants