Reputation: 3231
I'm stepping through some client-side JavaScript code that code like:
(function() {
'use strict';
debugger; //TODO
module.exports = function(utils, e)
Called by:
return require(name, dirname(path));
Does this mean that it's using node.js? This is client-side code that's using Backbone and JQuery.
-Eric
Upvotes: 0
Views: 55
Reputation: 887797
No.
This pattern is called CommonJS Modules; Node.js merely implemenets the pattern.
There are a number of implementations that run in the browser; Browserify is the most popular.
Upvotes: 3