Skip to content

Change packaging from Stitch to Browserify - #192

Merged
spikebrehm merged 38 commits into
rendrjs:masterfrom
akbarahmed:browserify
Dec 12, 2013
Merged

Change packaging from Stitch to Browserify#192
spikebrehm merged 38 commits into
rendrjs:masterfrom
akbarahmed:browserify

Conversation

@akbarahmed

Copy link
Copy Markdown
Contributor

Please note that I have temporarily pointed the package.json values for rendr and rendr-handlebars to my updated repos. Obviously, we'll need to change this to new tag numbers once the browserify update is in a tag for each repo.

This PR implements browserify for examples 00, 01, 02 and 03. Example 04 has other errors (such as not being updated for the moved app_view file) which need to be corrected before browserify makes sense.

I have also submitted a related RP for rendr-handlebars.

Related RP: rendrjs/rendr-handlebars#8

@selaux

selaux commented Nov 25, 2013

Copy link
Copy Markdown
Contributor

Can't you use browserify-shim instead of the Backbone.$ = window.$; workarounds? It's already included in grunt-browserify and also allows to specify dependencies between shimmed modules.

@akbarahmed

Copy link
Copy Markdown
Contributor Author

@selaux Yes, that's an option that's on my todo list.

There are positives and negatives to that approach. On the upside, jquery is also included via browserify. On the downside, using a CDN for jquery requires the use of an additional package (ex. bromote).

Comment thread examples/00_simple/Gruntfile.js Outdated

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Perhaps we can simplify some of this by adding in options to the browser field in rendr's package.json

@spikebrehm

Copy link
Copy Markdown
Member

Awesome how little modification it requires to simply switch over to Browserify. Still, there's lots of manual specifying where deps are, and which files to bundle, that I would hope to DRY up by rearranging the Rendr source files a bit to better accommodate Browserify, and/or using the browser field of package.json.

🍻

@spikebrehm

Copy link
Copy Markdown
Member

I've made a bunch of tweaks that get Browserify ready for primetime. Check out the PR to akbarahmed/browserify here: akbarahmed#4

spikebrehm pushed a commit that referenced this pull request Dec 12, 2013
Change packaging from Stitch to Browserify
@spikebrehm
spikebrehm merged commit 05c51ea into rendrjs:master Dec 12, 2013
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