Some problems related to build plugins - reminder

Hi, I just want to highlight and remind some problems related to preprocessors, Meteor build plugins system and stuff. I hope that there will be some time for Meteor’s build system improvements in near future because it is really important part of Meteor. I love that I don’t need to configure my build tools and everything just works, but here are the problems (my opinion and I’m aware that some of this problems were discussed, just a reminder on the occasion of the upcoming new version ;)):

  1. Stylus is forked and it’s not up to date, so I can use newest Stylus in my custom build plugin (for example: sGrid) but it will not work when I want to import some .styl files from packages, for example by @import '{test:package/test.styl}'. So I need to use old Stylus (forked one) or new one with broken imports. I think this isn’t good when we need to fork Stylus to make it work with Meteor.

  2. We don’t have official compiler for Scss. fourseven:scss is great but sometimes it isn’t updated too. And official one could be always on time.

  3. We need more configuration options (somehow). It is really hard to integrate such tools like PostCSS or for example customize and add some stylus plugins to the build process. (It could be also Less). For every such plugin I need to build new Stylus compiler or use some hacks with .json config files which seems to work, but not in all cases. What if I need to provide a custom function in the plugin configuration?

  4. [Important] With Meteor 1.3 we will have node_modules stuff, but again there is a problem because we can’t import .styl, .scss files from that folder and this is a serious blocker for now. I hope that this will land in Meteor 1.3 final version.
    Issue: https://github.com/meteor/meteor/issues/6037

I understand that it probably needs some major rewrites but I hope it could be done asap :wink: Because this part of Meteor gives really great user experience for newcommers. Problems occurs when we want to customize something or just update our favourite preprocessor :wink:

Any ideas about how we can make it easier for the community to solve these problems? I don’t think we have the ability to maintain official integrations for all of the CSS pre processors.

yeah, I know it could be hard :confused: I think for now the most important thing is to have the possibility to import scss, styl, less files from node_modules (from particular module) in 1.3. So in main .styl file in the app I should be able to @import 'from-node-modules-module-in-the-app/styles/file.styl'

For the rest problems, there are probably needed changes in the build plugins system so we don’t have to fork for example stylus to make it work, we might be able to just create custom build plugin with Stylus or Less or even Libsass Scss from Npm. Also we could have some kind of optional config .js file for the build system which could provide all customization and configuration for registered plugins. Unfortunatelly I have no idea how to achieve it, this is a job for someone smarter than me :confused:

Maybe when there will be no more ‘meteor packages’ it will be simpler to achieve it. I think the main reason why Stylus is forked is because specific imports like {test:package}/test.styl but I don’t know exactly.