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

Adding the r.js bundler using the requirejs and almond runtimes. #5

Merged
merged 1 commit into from Aug 20, 2016

Conversation

Projects
None yet
3 participants
@ryanfitzer
Contributor

ryanfitzer commented Aug 19, 2016

Also updated the concatenation of _markLoaded() and _markFinished() to make sure \n characters in require.js error messages aren't converted to new lines.

@ryanfitzer

This comment has been minimized.

Show comment
Hide comment
@ryanfitzer

ryanfitzer Aug 19, 2016

Contributor

Here are the results:

Results including r.js

Contributor

ryanfitzer commented Aug 19, 2016

Here are the results:

Results including r.js

@nolanlawson

This comment has been minimized.

Show comment
Hide comment
@nolanlawson

nolanlawson Aug 20, 2016

Owner

Wow, interesting stuff! Which browser did you run this on? Either way, very happy to merge.

I'm happy to see RequireJS do so well here; didn't realize it was so competitive with Browserify/Webpack. Hadn't heard of the Almond bundler, but perf-wise it seems pretty comparable to the default bundler?

Owner

nolanlawson commented Aug 20, 2016

Wow, interesting stuff! Which browser did you run this on? Either way, very happy to merge.

I'm happy to see RequireJS do so well here; didn't realize it was so competitive with Browserify/Webpack. Hadn't heard of the Almond bundler, but perf-wise it seems pretty comparable to the default bundler?

@nolanlawson nolanlawson merged commit 815ce48 into nolanlawson:master Aug 20, 2016

@phated

This comment has been minimized.

Show comment
Hide comment
@phated

phated Aug 20, 2016

Almond isn't a bundler. It's actually a shim that makes the final bundle behave more like browserify. It doesn't allow dynamic loads, etc. See https://github.com/requirejs/almond

phated commented Aug 20, 2016

Almond isn't a bundler. It's actually a shim that makes the final bundle behave more like browserify. It doesn't allow dynamic loads, etc. See https://github.com/requirejs/almond

@ryanfitzer

This comment has been minimized.

Show comment
Hide comment
@ryanfitzer

ryanfitzer Aug 21, 2016

Contributor

Which browser did you run this on?

Chrome 52 on OS X, running from localhost.

I'm happy to see RequireJS do so well here; didn't realize it was so competitive with Browserify/Webpack.

I was expecting it to do better on file size. I had a hunch the runtime numbers would be good. Glad to finally have some evidence.

Hadn't heard of the Almond bundler, but perf-wise it seems pretty comparable to the default bundler?

As @phated commented, it's a paired down version of RequireJS. If your production bundle can be loaded with a regular<script src>, Almond is the way to go.

There's also Alameda. Pretty much the same as RequireJS, but didn't add it because it only supports IE10+ and assumes Promises are available. Although, I did test it and was surprised it didn't do better than RequireJS on runtime:

alameda

Again, thanks for putting this together!

Contributor

ryanfitzer commented Aug 21, 2016

Which browser did you run this on?

Chrome 52 on OS X, running from localhost.

I'm happy to see RequireJS do so well here; didn't realize it was so competitive with Browserify/Webpack.

I was expecting it to do better on file size. I had a hunch the runtime numbers would be good. Glad to finally have some evidence.

Hadn't heard of the Almond bundler, but perf-wise it seems pretty comparable to the default bundler?

As @phated commented, it's a paired down version of RequireJS. If your production bundle can be loaded with a regular<script src>, Almond is the way to go.

There's also Alameda. Pretty much the same as RequireJS, but didn't add it because it only supports IE10+ and assumes Promises are available. Although, I did test it and was surprised it didn't do better than RequireJS on runtime:

alameda

Again, thanks for putting this together!

@nolanlawson

This comment has been minimized.

Show comment
Hide comment
@nolanlawson

nolanlawson Aug 21, 2016

Owner

Cool, I'd say Alameda is still interesting, since folks can drop in Promise shims to add IE<10 support. Seems like it doesn't offer a huge difference to almond/rjs, though.

Owner

nolanlawson commented Aug 21, 2016

Cool, I'd say Alameda is still interesting, since folks can drop in Promise shims to add IE<10 support. Seems like it doesn't offer a huge difference to almond/rjs, though.

@ryanfitzer

This comment has been minimized.

Show comment
Hide comment
@ryanfitzer

ryanfitzer Aug 24, 2016

Contributor

I can add it, if you like.

Contributor

ryanfitzer commented Aug 24, 2016

I can add it, if you like.

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