aboutsummaryrefslogtreecommitdiff
path: root/node_modules/builtin-modules
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/builtin-modules')
-rw-r--r--node_modules/builtin-modules/builtin-modules.json35
-rw-r--r--node_modules/builtin-modules/index.js10
-rw-r--r--node_modules/builtin-modules/license21
-rw-r--r--node_modules/builtin-modules/package.json40
-rw-r--r--node_modules/builtin-modules/readme.md41
-rw-r--r--node_modules/builtin-modules/static.js2
6 files changed, 149 insertions, 0 deletions
diff --git a/node_modules/builtin-modules/builtin-modules.json b/node_modules/builtin-modules/builtin-modules.json
new file mode 100644
index 000000000..72670f6bf
--- /dev/null
+++ b/node_modules/builtin-modules/builtin-modules.json
@@ -0,0 +1,35 @@
+[
+ "assert",
+ "buffer",
+ "child_process",
+ "cluster",
+ "console",
+ "constants",
+ "crypto",
+ "dgram",
+ "dns",
+ "domain",
+ "events",
+ "fs",
+ "http",
+ "https",
+ "module",
+ "net",
+ "os",
+ "path",
+ "process",
+ "punycode",
+ "querystring",
+ "readline",
+ "repl",
+ "stream",
+ "string_decoder",
+ "timers",
+ "tls",
+ "tty",
+ "url",
+ "util",
+ "v8",
+ "vm",
+ "zlib"
+]
diff --git a/node_modules/builtin-modules/index.js b/node_modules/builtin-modules/index.js
new file mode 100644
index 000000000..9ef35ab06
--- /dev/null
+++ b/node_modules/builtin-modules/index.js
@@ -0,0 +1,10 @@
+'use strict';
+
+var blacklist = [
+ 'freelist',
+ 'sys'
+];
+
+module.exports = Object.keys(process.binding('natives')).filter(function (el) {
+ return !/^_|^internal|\//.test(el) && blacklist.indexOf(el) === -1;
+}).sort();
diff --git a/node_modules/builtin-modules/license b/node_modules/builtin-modules/license
new file mode 100644
index 000000000..654d0bfe9
--- /dev/null
+++ b/node_modules/builtin-modules/license
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/builtin-modules/package.json b/node_modules/builtin-modules/package.json
new file mode 100644
index 000000000..430749aad
--- /dev/null
+++ b/node_modules/builtin-modules/package.json
@@ -0,0 +1,40 @@
+{
+ "name": "builtin-modules",
+ "version": "1.1.1",
+ "description": "List of the Node.js builtin modules",
+ "license": "MIT",
+ "repository": "sindresorhus/builtin-modules",
+ "author": {
+ "name": "Sindre Sorhus",
+ "email": "sindresorhus@gmail.com",
+ "url": "sindresorhus.com"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "scripts": {
+ "test": "xo && ava",
+ "make": "node make.js"
+ },
+ "files": [
+ "index.js",
+ "static.js",
+ "builtin-modules.json"
+ ],
+ "keywords": [
+ "builtin",
+ "built-in",
+ "builtins",
+ "node",
+ "modules",
+ "core",
+ "bundled",
+ "list",
+ "array",
+ "names"
+ ],
+ "devDependencies": {
+ "ava": "*",
+ "xo": "*"
+ }
+}
diff --git a/node_modules/builtin-modules/readme.md b/node_modules/builtin-modules/readme.md
new file mode 100644
index 000000000..f1894b189
--- /dev/null
+++ b/node_modules/builtin-modules/readme.md
@@ -0,0 +1,41 @@
+# builtin-modules [![Build Status](https://travis-ci.org/sindresorhus/builtin-modules.svg?branch=master)](https://travis-ci.org/sindresorhus/builtin-modules)
+
+> List of the Node.js builtin modules
+
+The list is just a [JSON file](builtin-modules.json) and can be used wherever.
+
+
+## Install
+
+```
+$ npm install --save builtin-modules
+```
+
+
+## Usage
+
+```js
+var builtinModules = require('builtin-modules');
+
+console.log(builinModules);
+//=> ['assert', 'buffer', ...]
+```
+
+
+## API
+
+Returns an array of builtin modules fetched from the running Node.js version.
+
+### Static list
+
+This module also comes bundled with a static array of builtin modules generated from the latest Node.js version. You can get it with `require('builtin-modules/static');`
+
+
+## Related
+
+- [is-builtin-module](https://github.com/sindresorhus/is-builtin-module) - Check if a string matches the name of a Node.js builtin module
+
+
+## License
+
+MIT © [Sindre Sorhus](http://sindresorhus.com)
diff --git a/node_modules/builtin-modules/static.js b/node_modules/builtin-modules/static.js
new file mode 100644
index 000000000..9508f8f4e
--- /dev/null
+++ b/node_modules/builtin-modules/static.js
@@ -0,0 +1,2 @@
+'use strict';
+module.exports = require('./builtin-modules.json');