Skip to content
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

Adds support for Promises returned in config, fixes #1503 #1731

Merged
merged 2 commits into from
Nov 22, 2017

Conversation

ankeetmaini
Copy link
Contributor

This PR is raised against #1503.

  • to account for cases where the config file actually does some async work to get options
  • added a test too

@ankeetmaini
Copy link
Contributor Author

cc: @Rich-Harris, @lukastaegert let me know if you still want this feature. Thanks :)

@lukastaegert
Copy link
Member

@ankeetmaini Yes, I find this VERY interesting! During JS Kongress this week I learned a lot about people using rollup in very creative ways to build very complex pipelines and I am sure those people would love this functionality.
My review pipeline has just grown a little long so stay tuned!

@ankeetmaini
Copy link
Contributor Author

@lukastaegert thanks so much! I'm interested in contributing to Rollup, is there an architecture note on how to understand the codebase?

@lukastaegert
Copy link
Member

Unfortunately not yet and, to be honest, things are a little in flux especially regarding the core tree-shaking algorithm. I hope to be able to write something up once things have settled down a little but probably not too soon.

👍🎉 for people who want to contribute!

If you want some ideas where to go next:

  • Things that improve the user experience are always heartily welcomed! I do not have a lot of time to look into these things and honestly, this is something that others are probably better suited to do. Your PR goes in this direction but we also need people to take care the documentation stays up to date with these enhancements.
  • Also to my knowledge, there are inconsistencies between the CLI interface and the config options that should be resolved at some point.
  • I hear there are some issues related to caching that I do not expect to find any time to look at soon.
  • Or anything else from the issues list 😁 Maybe make a comment if start to work at a PR for an issue. That way, people are aware of this and might give you input and it would also prevent work being done twice.

Copy link
Member

@lukastaegert lukastaegert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! You might want to remove the file I marked. Beyond that, I plan on merging this into the next non-patch release!

@@ -0,0 +1,11 @@
(function (global, factory) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Including this file does not have an effect as it is only checked if you do NOT set execute: true in _config.js. You should remove it as it is rather confusing (and while you are at it, remove it from the cli/config test as well 😜)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You got it!

@lukastaegert lukastaegert added this to the 0.52.0 milestone Nov 16, 2017
Copy link
Member

@lukastaegert lukastaegert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I'll put it into the next feature release.

@lukastaegert
Copy link
Member

lukastaegert commented Nov 17, 2017

BTW we should document this on the web site. If someone were to prepare a PR for https://github.com/rollup/rollupjs.org that describes this feature and at the same time also addresses rollup/rollupjs.org#69, that would be awesome!
Otherwise, we should probably add this to rollup/rollupjs.org#69 once the feature is released.

@ankeetmaini
Copy link
Contributor Author

I'll take a look!

@lukastaegert lukastaegert changed the base branch from master to release-0.52 November 22, 2017 05:34
@lukastaegert lukastaegert merged commit a11c5a2 into rollup:release-0.52 Nov 22, 2017
@lukastaegert
Copy link
Member

I have started to assemble a branch for the next release but it will take another few days until I release it because I there are a few more PRs I want to have in there which are not ready yet.

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

Successfully merging this pull request may close these issues.

None yet

2 participants