var fs = require('fs'); I'd like to understand this a little more, require is part of v8 JS? or nodejs function? if yes, where can I find it in Nodejs's source code? thanks,
> var fs = require('fs');
> I'd like to understand this a little more, require is part of v8 JS? or > nodejs function? if yes, where can I find it in Nodejs's source code? > thanks,
Thanks for the direction, but I found it at beg of module.js, it has a
line:
var NativeModule = require('native_module');
is the require here refers to:
> четверг, 15 ноября 2012 г., 16:17:32 UTC+4 пользователь Angelo Chen написал:
> > Hi,
> > var fs = require('fs');
> > I'd like to understand this a little more, require is part of v8 JS? or
> > nodejs function? if yes, where can I find it in Nodejs's source code?
> > thanks,
> Thanks for the direction, but I found it at beg of module.js, it has a > line: > var NativeModule = require('native_module'); > is the require here refers to:
> > четверг, 15 ноября 2012 г., 16:17:32 UTC+4 пользователь Angelo Chen > написал:
> > > Hi,
> > > var fs = require('fs'); > > > I'd like to understand this a little more, require is part of v8 JS? > or > > > nodejs function? if yes, where can I find it in Nodejs's source code? > > > thanks,
On Thu, Nov 15, 2012 at 6:20 AM, Angelo Chen <angelochen...@gmail.com>wrote:
> Hi,
> Thanks for the direction, but I found it at beg of module.js, it has a
> line:
> var NativeModule = require('native_module');
> is the require here refers to:
I'm afraid you're going to have to keep reading. :-) You'll discover that
ultimately 'require' is a function that is unique for each module, and is
passed in to the wrapper that executes the module. See:
> > четверг, 15 ноября 2012 г., 16:17:32 UTC+4 пользователь Angelo Chen
> написал:
> > > Hi,
> > > var fs = require('fs');
> > > I'd like to understand this a little more, require is part of v8 JS? or
> > > nodejs function? if yes, where can I find it in Nodejs's source code?
> > > thanks,