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

Split tween.js into separate files and bundle it with rollup. #331

Closed
wants to merge 1 commit into from

Conversation

martikaljuve
Copy link
Contributor

Similar to #327, but using Rollup + Bublé instead of babel to get a minimal bundle.

  • changed jscs and jshint to run on the whole src dir.

@trusktr
Copy link
Member

trusktr commented Mar 22, 2017

Hello Marti!

  • I think this PR is too big. Maybe let's first settle on a transpilation tool (Babel vs Buble, never saw Buble before, am going to check it out). Can you make a new PR with just Buble, no file separation, so we can compare them? Then we can move on to Rollup vs Webpack vs Browserify vs etc.
  • I like the concept of rollup, but if you use it in bigger projects you'll find that it may still have bugs. Babel's (and Webpack's) ES6 module is more solid.

@trusktr
Copy link
Member

trusktr commented Mar 22, 2017

I like the file separation though! I just think it may be better to introduce smaller changes. I'm reading up on Buble now, looks cool.

@trusktr
Copy link
Member

trusktr commented Mar 22, 2017

The output of Buble looks.... really nice.

The question is, is it mature enough (as Babel)? For example, try this in Buble repl:

let s = foo`
  hello ${name}!
  it's good to see you`;

@trusktr
Copy link
Member

trusktr commented Mar 22, 2017

After thinking about it for a moment, I'm in favor of merging this commit because

  • the output is cleaner than Babel (with acceptable limitations that I think we are fine with ATM and that perform better than Babel),
  • the file separation is really nice,
  • and we most likely won't run into any rollup bugs in this simple case.

Would the commit message need to be modified so that it follow semantic-release format? f.e. refactor: split tween.js into separate files and bundle it with rollup (no capital first letter, no period).

Copy link
Member

@trusktr trusktr left a comment

Choose a reason for hiding this comment

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

I like

@martikaljuve
Copy link
Contributor Author

For reference, here's the bundled dist/TWEEN.js file that Rollup creates: https://gist.github.com/martikaljuve/a0629891480245aa31fc57f6724bbf7d

@martikaljuve martikaljuve mentioned this pull request Mar 22, 2017
@trusktr
Copy link
Member

trusktr commented Mar 27, 2017

@martikaljuve It is clean output!

@trusktr
Copy link
Member

trusktr commented Aug 2, 2017

I'm trying to switch a project of mine to Buble, but no luck: https://gitlab.com/Rich-Harris/buble/issues/206

@mikebolt
Copy link
Contributor

mikebolt commented Aug 2, 2017 via email

@trusktr
Copy link
Member

trusktr commented Sep 16, 2017

@martikaljuve I finished switching infamous to Rollup+Buble, the result is awesome (the lean and clean output code).

Can you resolve conflicts so we can move forward with the idea here?

@mikebolt
Copy link
Contributor

mikebolt commented Sep 1, 2019

I just merged in another PR for Rollup.

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.

3 participants