[nodejs] announcing browserify v2

2013-02-22 Thread substack
browserify v2 was just released! browserify lets you write node-style require() calls for browser code so that you can package up your scripts and npm modules into a single bundle to serve to browsers. browserify implements exactly the node_modules lookup algorithm so you can use many libraries

Re: [nodejs] announcing browserify v2

2013-02-22 Thread substack
On Friday, February 22, 2013 6:44:45 PM UTC-8, Nathan Rajlich wrote: > Is Buffer automatically bundled when it's use is detected in your code now? > Not yet but this would be fairly simple to add to the insert-module-globals module. Expect this soon. -- -- Job Board: http://jobs.nodejs.org/ P

Re: [nodejs] announcing browserify v2

2013-03-01 Thread substack
complainers you predicted. > Now in v2.3 there's a `.transform()` api for all those who missed coffee-script from the https://github.com/substack/node-browserify#btransformtr >From the command-line compiling coffee-script is now as simple as: browserify -c 'coffee -sc' main.c

Re: [nodejs] Module pattern feedback

2013-03-23 Thread substack
On Saturday, March 23, 2013 5:22:12 PM UTC-7, Rick Waldron wrote: > Why do module authors make gross factory APIs? > > Instead of wrapping the export in this icky "createLogger" method, that > doesn't do _anything_ (one assumes a factory exists to provide some > additional layer of logic over th

Re: [nodejs] hostproxy

2013-04-19 Thread substack
> Bouncy parses HTTP it just uses a minimal pure JavaScript parser which, last time i checked, > wasn't faster than the node's HTTP parser but does support some offset information that is > needed for header injection. In version 3 bouncy switched back to using the core http module but it expos

[nodejs] Re: Issues using request with browserify

2012-11-25 Thread substack
On Sunday, November 25, 2012 4:40:54 PM UTC-8, Simon wrote: > > Has anyone had any luck using mikeal's request with browserify. I kinda > hoped it would just work, but the issue I run into is "Object has no method > readFileSync" from within Mime.prototype.load so I may need to find a way > to l

[nodejs] a new service to run your browser tests on every commit

2012-12-11 Thread substack
t;testling" field to your package.json like this: https://github.com/substack/node-falafel/blob/master/package.json#L41-L50 then add a github webhook for "http://git.testling.com"; and your browser tests will be run on every commit in exactly the browsers you've specified! Yo

[nodejs] Re: Implement Password Reset in Node.js

2012-05-13 Thread substack
I've wrote a module to do this: https://github.com/substack/node-password-reset It's not tied to any particular database, it just persists the records in memory. You could save the data to a database pretty easily though. On Sunday, May 13, 2012 4:46:13 AM UTC-7, Feras Odeh wrote: >

[nodejs] Re: Porting fs to the browser via browserify

2012-05-22 Thread substack
On Tuesday, May 22, 2012 12:55:48 PM UTC-7, Adam Crabtree wrote: > > For the curious, Substack's on board with including the eventual (assuming > it works) builtin into browserify. > > My fork of node-browserify for fs.js development (to eventually submit a > pull request) (there's nothing there

[nodejs] Re: Best practices for sharing code and data between the server and client

2012-05-30 Thread substack
with the client, and there are no default way for doing > that. > browserify lets you do node-style require()s in the browser, so a lot of node code will just work browser-side, including many packages from npm https://github.com/substack/node-browserify -- Job Board: http://jobs.node

Re: [nodejs] Re: "Standard" Test Runner for Node

2012-07-17 Thread substack
On Tuesday, July 17, 2012 3:13:44 AM UTC-7, Alex Young wrote: > The CommonJS test module uses those export-based tests, and somehow I've been assuming this is the 'right' way to write tests. It seems like there are three options: > * CommonJS unit testing module style > * Mocha (and similar) wher

[nodejs] Re: how to write for-each loop in JavaScript properly

2012-02-13 Thread substack
On Feb 13, 7:01 am, Axel Kittenberger wrote: > Why they didn't make the standard forEach in that returning false > terminates the loop is beyond me... You can just abuse the short-circuiting of [].some: > [ 1, 2, 3, 4, 5, 6, 7 ].some(function (x) { console.log(x); if (x > 4) return > true }) 1