[nodejs] ender vs. browserify?
I am new to both ender vs. browserify. Can someone summarize their differences, advantages, etc? -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
Re: [nodejs] ender vs. browserify?
Ender targets front-end projects. Tools like OneJS (http://github.com/azer/onejs) and Browserify let you follow the CommonJS way and code your web projects as CommonJS packages. OneJS is the tool I maintain and I highly recommend it. It produces unobtrusive, well structured code and lets you use all Node goodies like NPM. You may take a look at the homepage of OneJS to see more details and real world examples. Best, Azer On Sat, Apr 21, 2012 at 11:56 AM, Mark Hahn wrote: > I am new to both ender vs. browserify. Can someone summarize their > differences, advantages, etc? > > -- > Job Board: http://jobs.nodejs.org/ > Posting guidelines: > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > You received this message because you are subscribed to the Google > Groups "nodejs" group. > To post to this group, send email to nodejs@googlegroups.com > To unsubscribe from this group, send email to > nodejs+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/nodejs?hl=en?hl=en -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
Re: [nodejs] ender vs. browserify?
> OneJS moves the revolution of NPM one step forward and makes it available for client-side projects! Does this mean you can load a module directly from the npm registry into the client to run? Can you also query the registry? -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
Re: [nodejs] ender vs. browserify?
browserify has _by far_ the most test coverage. I know from my own dabbling in the problem that there are _alot_ of edgecases. https://github.com/substack/node-browserify/tree/master/test I just use browserify now On Mon, Apr 23, 2012 at 6:07 AM, Mark Hahn wrote: > > OneJS moves the revolution of NPM one step forward and makes it > available for client-side projects! > > Does this mean you can load a module directly from the npm registry into > the client to run? Can you also query the registry? > > -- > Job Board: http://jobs.nodejs.org/ > Posting guidelines: > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > You received this message because you are subscribed to the Google > Groups "nodejs" group. > To post to this group, send email to nodejs@googlegroups.com > To unsubscribe from this group, send email to > nodejs+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/nodejs?hl=en?hl=en > -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
Re: [nodejs] ender vs. browserify?
Does browserify let you install npm modules, similar to `ender build , or do you have to manually download them? -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
Re: [nodejs] ender vs. browserify?
> Does browserify let you install npm modules, similar to `ender build package names>, or do you have to manually download them? You install modules with npm, and require them in your browser's index.js . Then you do a browserify build against that index.js and it bundles the deps automatically. I don't know much of anything about ender, but if you're going for "client side require system" browserify's pretty much where it's at. -Josh On Sun, Apr 22, 2012 at 10:43 PM, Jamison Dance wrote: > Does browserify let you install npm modules, similar to `ender build package names>, or do you have to manually download them? > > -- > Job Board: http://jobs.nodejs.org/ > Posting guidelines: > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > You received this message because you are subscribed to the Google > Groups "nodejs" group. > To post to this group, send email to nodejs@googlegroups.com > To unsubscribe from this group, send email to > nodejs+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/nodejs?hl=en?hl=en -- Joshua Holbrook Engineer Nodejitsu Inc. j...@nodejitsu.com -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
Re: [nodejs] ender vs. browserify?
Neat. Sounds like I could just use a package.json file for my client-side files, do an `npm install`, and then a browserify build, which is a nice workflow. > -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
Re: [nodejs] ender vs. browserify?
I am thinking of putting the entire app in a client-side browserify bundle. I can create the entire BODY element of the dom from js code including the style info. The idea here is to release an app by just releasing the bundle. I could create a generic index.html file that requires the bundle. I have one question though. How/where would I store my image files? I can imagine putting image files in package folders installed from npm but then how would I serve them? I doubt I want the node_modules folder inside my web root folder. :-) -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
Re: [nodejs] ender vs. browserify?
you'd probably still need a bit on the server side, for validation. you wouldn't want to give the browser direct access to your database for example. On Mon, Apr 23, 2012 at 6:10 PM, Mark Hahn wrote: > I am thinking of putting the entire app in a client-side browserify > bundle. I can create the entire BODY element of the dom from js code > including the style info. The idea here is to release an app by just > releasing the bundle. > > I could create a generic index.html file that requires the bundle. > > I have one question though. How/where would I store my image files? I > can imagine putting image files in package folders installed from npm but > then how would I serve them? I doubt I want the node_modules folder inside > my web root folder. :-) > > -- > Job Board: http://jobs.nodejs.org/ > Posting guidelines: > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > You received this message because you are subscribed to the Google > Groups "nodejs" group. > To post to this group, send email to nodejs@googlegroups.com > To unsubscribe from this group, send email to > nodejs+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/nodejs?hl=en?hl=en > -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
Re: [nodejs] ender vs. browserify?
On Sun, Apr 22, 2012 at 9:11 PM, Dominic Tarr wrote: > browserify has _by far_ the most test coverage. I know from my own dabbling > in the problem that there are _alot_ of edgecases. I confidently say that OneJS is a well-tested project that faced _more_ edge-cases already and solved those issues. And I think browserify has some issues which can't be considered as edge-cases, e.g; polluting global scope, a lot. To have an idea of the accuracy of OneJS, check the following examples; - MultiplayerChess.com built with OneJS: http://multiplayerchess.com/mpc.js - ExpressJS built with OneJS: https://gist.github.com/2415048 ExpressJS is not a client-side project but it's a good example project to see the accuracy of the implementations of CommonJS specs. And I get following error when I try to build it with browserify; > ./node_modules/.bin/browserify index.js -o express.js Expressions in require() statements: require("./middleware/"+name) Expressions in require() statements: require(this.engine) SyntaxError: 'return' outside of function at line 22:32 in expression: if (res._hasConnectPatch) return; at /home/azer/dev/express/node_modules/browserify/node_modules/deputy/node_modules/detective/node_modules/burrito/index.js:16:17 at /home/azer/dev/express/node_modules/browserify/node_modules/deputy/node_modules/detective/node_modules/burrito/index.js:41:11 at Function.find (/home/azer/dev/express/node_modules/browserify/node_modules/deputy/node_modules/detective/index.js:15:5) at Function.find (/home/azer/dev/express/node_modules/browserify/node_modules/deputy/index.js:38:27) at Function. (/home/azer/dev/express/node_modules/browserify/lib/wrap.js:435:39) at Function.require (/home/azer/dev/express/node_modules/browserify/index.js:155:28) at /home/azer/dev/express/node_modules/browserify/lib/wrap.js:458:14 at Array.forEach (native) at Function. (/home/azer/dev/express/node_modules/browserify/lib/wrap.js:457:27) at Function.require (/home/azer/dev/express/node_modules/browserify/index.js:155:28) Best, Azer > > https://github.com/substack/node-browserify/tree/master/test > > I just use browserify now > > > On Mon, Apr 23, 2012 at 6:07 AM, Mark Hahn wrote: >> >> > OneJS moves the revolution of NPM one step forward and makes it >> > available for client-side projects! >> >> Does this mean you can load a module directly from the npm registry into >> the client to run? Can you also query the registry? >> >> -- >> Job Board: http://jobs.nodejs.org/ >> Posting guidelines: >> https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines >> You received this message because you are subscribed to the Google >> Groups "nodejs" group. >> To post to this group, send email to nodejs@googlegroups.com >> To unsubscribe from this group, send email to >> nodejs+unsubscr...@googlegroups.com >> For more options, visit this group at >> http://groups.google.com/group/nodejs?hl=en?hl=en > > > -- > Job Board: http://jobs.nodejs.org/ > Posting guidelines: > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > You received this message because you are subscribed to the Google > Groups "nodejs" group. > To post to this group, send email to nodejs@googlegroups.com > To unsubscribe from this group, send email to > nodejs+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/nodejs?hl=en?hl=en -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
Re: [nodejs] ender vs. browserify?
oh right, that is because you are listing a directory and then requiring each item automatically. how does onejs handle that case? you are right about browserify poluting the global namespace. it should define it's stuff inside a closure. On Tue, Apr 24, 2012 at 12:11 PM, Azer Koçulu wrote: > On Sun, Apr 22, 2012 at 9:11 PM, Dominic Tarr > wrote: > > browserify has _by far_ the most test coverage. I know from my own > dabbling > > in the problem that there are _alot_ of edgecases. > > I confidently say that OneJS is a well-tested project that faced > _more_ edge-cases already and solved those issues. And I think > browserify has some issues which can't be considered as edge-cases, > e.g; polluting global scope, a lot. > > To have an idea of the accuracy of OneJS, check the following examples; > - MultiplayerChess.com built with OneJS: > http://multiplayerchess.com/mpc.js > - ExpressJS built with OneJS: https://gist.github.com/2415048 > > ExpressJS is not a client-side project but it's a good example project > to see the accuracy of the implementations of CommonJS specs. And I > get following error when I try to build it with browserify; > > > ./node_modules/.bin/browserify index.js -o express.js > Expressions in require() statements: >require("./middleware/"+name) > Expressions in require() statements: >require(this.engine) > SyntaxError: 'return' outside of function > at line 22:32 in expression: > > if (res._hasConnectPatch) return; >at > /home/azer/dev/express/node_modules/browserify/node_modules/deputy/node_modules/detective/node_modules/burrito/index.js:16:17 >at > /home/azer/dev/express/node_modules/browserify/node_modules/deputy/node_modules/detective/node_modules/burrito/index.js:41:11 >at Function.find > > (/home/azer/dev/express/node_modules/browserify/node_modules/deputy/node_modules/detective/index.js:15:5) >at Function.find > > (/home/azer/dev/express/node_modules/browserify/node_modules/deputy/index.js:38:27) >at Function. > (/home/azer/dev/express/node_modules/browserify/lib/wrap.js:435:39) >at Function.require > (/home/azer/dev/express/node_modules/browserify/index.js:155:28) >at /home/azer/dev/express/node_modules/browserify/lib/wrap.js:458:14 >at Array.forEach (native) >at Function. > (/home/azer/dev/express/node_modules/browserify/lib/wrap.js:457:27) >at Function.require > (/home/azer/dev/express/node_modules/browserify/index.js:155:28) > > > > Best, > > Azer > > > > > https://github.com/substack/node-browserify/tree/master/test > > > > I just use browserify now > > > > > > On Mon, Apr 23, 2012 at 6:07 AM, Mark Hahn wrote: > >> > >> > OneJS moves the revolution of NPM one step forward and makes it > >> > available for client-side projects! > >> > >> Does this mean you can load a module directly from the npm registry into > >> the client to run? Can you also query the registry? > >> > >> -- > >> Job Board: http://jobs.nodejs.org/ > >> Posting guidelines: > >> https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > >> You received this message because you are subscribed to the Google > >> Groups "nodejs" group. > >> To post to this group, send email to nodejs@googlegroups.com > >> To unsubscribe from this group, send email to > >> nodejs+unsubscr...@googlegroups.com > >> For more options, visit this group at > >> http://groups.google.com/group/nodejs?hl=en?hl=en > > > > > > -- > > Job Board: http://jobs.nodejs.org/ > > Posting guidelines: > > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > > You received this message because you are subscribed to the Google > > Groups "nodejs" group. > > To post to this group, send email to nodejs@googlegroups.com > > To unsubscribe from this group, send email to > > nodejs+unsubscr...@googlegroups.com > > For more options, visit this group at > > http://groups.google.com/group/nodejs?hl=en?hl=en > > -- > Job Board: http://jobs.nodejs.org/ > Posting guidelines: > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > You received this message because you are subscribed to the Google > Groups "nodejs" group. > To post to this group, send email to nodejs@googlegroups.com > To unsubscribe from this group, send email to > nodejs+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/nodejs?hl=en?hl=en > -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
Re: [nodejs] ender vs. browserify?
another question, how does onejs figure out which .js files are required? browserify parses the js, then traverses the ast looking for calls to require(). On Tue, Apr 24, 2012 at 12:43 PM, Dominic Tarr wrote: > oh right, that is because you are listing a directory and then requiring > each item automatically. > > how does onejs handle that case? > > you are right about browserify poluting the global namespace. it should > define it's stuff inside a closure. > > On Tue, Apr 24, 2012 at 12:11 PM, Azer Koçulu wrote: > >> On Sun, Apr 22, 2012 at 9:11 PM, Dominic Tarr >> wrote: >> > browserify has _by far_ the most test coverage. I know from my own >> dabbling >> > in the problem that there are _alot_ of edgecases. >> >> I confidently say that OneJS is a well-tested project that faced >> _more_ edge-cases already and solved those issues. And I think >> browserify has some issues which can't be considered as edge-cases, >> e.g; polluting global scope, a lot. >> >> To have an idea of the accuracy of OneJS, check the following examples; >> - MultiplayerChess.com built with OneJS: >> http://multiplayerchess.com/mpc.js >> - ExpressJS built with OneJS: https://gist.github.com/2415048 >> >> ExpressJS is not a client-side project but it's a good example project >> to see the accuracy of the implementations of CommonJS specs. And I >> get following error when I try to build it with browserify; >> >> > ./node_modules/.bin/browserify index.js -o express.js >> Expressions in require() statements: >>require("./middleware/"+name) >> Expressions in require() statements: >>require(this.engine) >> SyntaxError: 'return' outside of function >> at line 22:32 in expression: >> >> if (res._hasConnectPatch) return; >>at >> /home/azer/dev/express/node_modules/browserify/node_modules/deputy/node_modules/detective/node_modules/burrito/index.js:16:17 >>at >> /home/azer/dev/express/node_modules/browserify/node_modules/deputy/node_modules/detective/node_modules/burrito/index.js:41:11 >>at Function.find >> >> (/home/azer/dev/express/node_modules/browserify/node_modules/deputy/node_modules/detective/index.js:15:5) >>at Function.find >> >> (/home/azer/dev/express/node_modules/browserify/node_modules/deputy/index.js:38:27) >>at Function. >> (/home/azer/dev/express/node_modules/browserify/lib/wrap.js:435:39) >>at Function.require >> (/home/azer/dev/express/node_modules/browserify/index.js:155:28) >>at /home/azer/dev/express/node_modules/browserify/lib/wrap.js:458:14 >>at Array.forEach (native) >>at Function. >> (/home/azer/dev/express/node_modules/browserify/lib/wrap.js:457:27) >>at Function.require >> (/home/azer/dev/express/node_modules/browserify/index.js:155:28) >> >> >> >> Best, >> >> Azer >> >> > >> > https://github.com/substack/node-browserify/tree/master/test >> > >> > I just use browserify now >> > >> > >> > On Mon, Apr 23, 2012 at 6:07 AM, Mark Hahn wrote: >> >> >> >> > OneJS moves the revolution of NPM one step forward and makes it >> >> > available for client-side projects! >> >> >> >> Does this mean you can load a module directly from the npm registry >> into >> >> the client to run? Can you also query the registry? >> >> >> >> -- >> >> Job Board: http://jobs.nodejs.org/ >> >> Posting guidelines: >> >> https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines >> >> You received this message because you are subscribed to the Google >> >> Groups "nodejs" group. >> >> To post to this group, send email to nodejs@googlegroups.com >> >> To unsubscribe from this group, send email to >> >> nodejs+unsubscr...@googlegroups.com >> >> For more options, visit this group at >> >> http://groups.google.com/group/nodejs?hl=en?hl=en >> > >> > >> > -- >> > Job Board: http://jobs.nodejs.org/ >> > Posting guidelines: >> > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines >> > You received this message because you are subscribed to the Google >> > Groups "nodejs" group. >> > To post to this group, send email to nodejs@googlegroups.com >> > To unsubscribe from this group, send email to >> > nodejs+unsubscr...@googlegroups.com >> > For more options, visit this group at >> > http://groups.google.com/group/nodejs?hl=en?hl=en >> >> -- >> Job Board: http://jobs.nodejs.org/ >> Posting guidelines: >> https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines >> You received this message because you are subscribed to the Google >> Groups "nodejs" group. >> To post to this group, send email to nodejs@googlegroups.com >> To unsubscribe from this group, send email to >> nodejs+unsubscr...@googlegroups.com >> For more options, visit this group at >> http://groups.google.com/group/nodejs?hl=en?hl=en >> > > -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegrou
Re: [nodejs] ender vs. browserify?
By the way there's also Brunch https://github.com/brunch/brunch -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en