Skip to content
This repository has been archived by the owner on Dec 19, 2024. It is now read-only.

Rename from/to options to source/dest ? #160

Closed
MoOx opened this issue Jun 23, 2015 · 11 comments
Closed

Rename from/to options to source/dest ? #160

MoOx opened this issue Jun 23, 2015 · 11 comments

Comments

@MoOx
Copy link
Owner

MoOx commented Jun 23, 2015

I always found from & to option where pretty shitty and I am not sure we should keep them.
We might introduce this change in a major release.

Any thoughts ?

@ben-eb
Copy link
Contributor

ben-eb commented Jun 23, 2015

Where possible it would be good to be consistent with what the rest of the PostCSS ecosystem is doing. I think any such change should be in PostCSS itself to maintain that consistency.

@MoOx
Copy link
Owner Author

MoOx commented Jun 23, 2015

These options are only relevant if you are using cssnext directly, not through postcss. So not sure if it's a requirement. But if @ai is open to this kind of improvement, why not.

@ben-eb
Copy link
Contributor

ben-eb commented Jun 23, 2015

Yep, but it is nicer if all of our modules use the same options for source maps; so that if a user of a PostCSS module wants source maps, she doesn't have to apply different options when wanting to use cssnext instead. 😄

@MoOx
Copy link
Owner Author

MoOx commented Jun 23, 2015

I don't consider cssnext as a postcss plugin (mostly because I think most people should not use postcss directly - like babel user that don't use acorn directly).
I have plan for v2 to change it's API and this issue will probably be part of it.

@ai
Copy link

ai commented Jun 23, 2015

@MoOx I understand you, but without a main PostCSS runner there will not be a way for small and new plugins for developer. We will stagnation.

@MoOx
Copy link
Owner Author

MoOx commented Jun 23, 2015

I am not sure about what you are saying @ai.
Anyway, would you consider renaming from/to to source/destination in the next major release ?

@ai
Copy link

ai commented Jun 23, 2015

My idea is that if user use gulp-postcss, instead of postcss autoprefixer or gulp-cssnext, he can add also many other small PostCSS plugins, like postcss-data-packer. So market will be open for new ideas. With gulp-autoprefixer it is psychology more difficult to add new plugin for user.

@MoOx
Copy link
Owner Author

MoOx commented Jun 23, 2015

cssnext now have a plugin option to pipe others plugins :)
http://cssnext.io/usage/#plugins

@ai
Copy link

ai commented Jun 23, 2015

We can rename it, of course.

But why they are better? It is only question of taste our there is any objective benefits.

What Babel uses?

@MoOx
Copy link
Owner Author

MoOx commented Jun 23, 2015

Babel don't have this kind of options.
But src/source and dest/destination are much more common than from/to in a lot of open source projects (metalsmith, gulp, grunt...).

@MoOx
Copy link
Owner Author

MoOx commented Aug 6, 2015

Should be a postcss issue.

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

No branches or pull requests

3 participants