Debian Codegraph @

workspaces/arborist/test/fixtures/registry-mocks/content/detect-node.json

raw
1 {
2 "_id": "detect-node",
3 "_rev": "14-a2d69a62996b39bd5394e0f0baf686a7",
4 "name": "detect-node",
5 "description": "Detect Node.JS (as opposite to browser environment) (reliable)",
6 "dist-tags": {
7 "latest": "2.0.4"
8 },
9 "versions": {
10 "1.0.0": {
11 "name": "detect-node",
12 "version": "1.0.0",
13 "description": "Detect Node.JS (as opposite to browser environment) (reliable)",
14 "main": "index.js",
15 "scripts": {
16 "test": "echo \"Error: no test specified\" && exit 1"
17 },
18 "repository": {
19 "type": "git",
20 "url": "https://github.com/iliakan/detect-node"
21 },
22 "keywords": [
23 "detect",
24 "node"
25 ],
26 "author": {
27 "name": "Ilya Kantor"
28 },
29 "license": "ISC",
30 "bugs": {
31 "url": "https://github.com/iliakan/detect-node/issues"
32 },
33 "homepage": "https://github.com/iliakan/detect-node",
34 "_id": "[email protected]",
35 "_shasum": "0dce710909dcb78d46a44889f8b78c983d27f1df",
36 "_from": ".",
37 "_npmVersion": "1.4.21",
38 "_npmUser": {
39 "name": "iliakan",
40 "email": "[email protected]"
41 },
42 "maintainers": [
43 {
44 "name": "iliakan",
45 "email": "[email protected]"
46 }
47 ],
48 "dist": {
49 "shasum": "0dce710909dcb78d46a44889f8b78c983d27f1df",
50 "tarball": "https://registry.npmjs.org/detect-node/-/detect-node-1.0.0.tgz"
51 },
52 "directories": {}
53 },
54 "2.0.0": {
55 "name": "detect-node",
56 "version": "2.0.0",
57 "description": "Detect Node.JS (as opposite to browser environment) (reliable)",
58 "main": "index.js",
59 "scripts": {
60 "test": "echo \"Error: no test specified\" && exit 1"
61 },
62 "repository": {
63 "type": "git",
64 "url": "https://github.com/iliakan/detect-node"
65 },
66 "keywords": [
67 "detect",
68 "node"
69 ],
70 "author": {
71 "name": "Ilya Kantor"
72 },
73 "license": "ISC",
74 "bugs": {
75 "url": "https://github.com/iliakan/detect-node/issues"
76 },
77 "homepage": "https://github.com/iliakan/detect-node",
78 "gitHead": "3e1d2591bdbf5e3ac1d36f4b81ddb91f37fc2280",
79 "_id": "[email protected]",
80 "_shasum": "5ed01329818006b14a19ac8f68ec1e1a65cce725",
81 "_from": ".",
82 "_npmVersion": "1.4.21",
83 "_npmUser": {
84 "name": "iliakan",
85 "email": "[email protected]"
86 },
87 "maintainers": [
88 {
89 "name": "iliakan",
90 "email": "[email protected]"
91 }
92 ],
93 "dist": {
94 "shasum": "5ed01329818006b14a19ac8f68ec1e1a65cce725",
95 "tarball": "https://registry.npmjs.org/detect-node/-/detect-node-2.0.0.tgz"
96 },
97 "directories": {}
98 },
99 "2.0.1": {
100 "name": "detect-node",
101 "version": "2.0.1",
102 "description": "Detect Node.JS (as opposite to browser environment) (reliable)",
103 "main": "index.js",
104 "scripts": {
105 "test": "echo \"Error: no test specified\" && exit 1"
106 },
107 "repository": {
108 "type": "git",
109 "url": "https://github.com/iliakan/detect-node"
110 },
111 "keywords": [
112 "detect",
113 "node"
114 ],
115 "author": {
116 "name": "Ilya Kantor"
117 },
118 "license": "ISC",
119 "bugs": {
120 "url": "https://github.com/iliakan/detect-node/issues"
121 },
122 "homepage": "https://github.com/iliakan/detect-node",
123 "_id": "[email protected]",
124 "_shasum": "d10f1b84000e46670f9f3d1456d92d07a3ac3bdf",
125 "_from": ".",
126 "_npmVersion": "1.4.9",
127 "_npmUser": {
128 "name": "iliakan",
129 "email": "[email protected]"
130 },
131 "maintainers": [
132 {
133 "name": "iliakan",
134 "email": "[email protected]"
135 }
136 ],
137 "dist": {
138 "shasum": "d10f1b84000e46670f9f3d1456d92d07a3ac3bdf",
139 "tarball": "https://registry.npmjs.org/detect-node/-/detect-node-2.0.1.tgz"
140 },
141 "directories": {}
142 },
143 "2.0.2": {
144 "name": "detect-node",
145 "version": "2.0.2",
146 "description": "Detect Node.JS (as opposite to browser environment) (reliable)",
147 "main": "index.js",
148 "scripts": {
149 "test": "echo \"Error: no test specified\" && exit 1"
150 },
151 "repository": {
152 "type": "git",
153 "url": "https://github.com/iliakan/detect-node"
154 },
155 "keywords": [
156 "detect",
157 "node"
158 ],
159 "author": {
160 "name": "Ilya Kantor"
161 },
162 "license": "ISC",
163 "bugs": {
164 "url": "https://github.com/iliakan/detect-node/issues"
165 },
166 "homepage": "https://github.com/iliakan/detect-node",
167 "_id": "[email protected]",
168 "_shasum": "1d35ceac9f2b4becc5e8eae0f46a70c730e921f5",
169 "_from": ".",
170 "_npmVersion": "1.4.9",
171 "_npmUser": {
172 "name": "iliakan",
173 "email": "[email protected]"
174 },
175 "maintainers": [
176 {
177 "name": "iliakan",
178 "email": "[email protected]"
179 }
180 ],
181 "dist": {
182 "shasum": "1d35ceac9f2b4becc5e8eae0f46a70c730e921f5",
183 "tarball": "https://registry.npmjs.org/detect-node/-/detect-node-2.0.2.tgz"
184 },
185 "directories": {}
186 },
187 "2.0.3": {
188 "name": "detect-node",
189 "version": "2.0.3",
190 "description": "Detect Node.JS (as opposite to browser environment) (reliable)",
191 "main": "index.js",
192 "scripts": {
193 "test": "echo \"Error: no test specified\" && exit 1"
194 },
195 "repository": {
196 "type": "git",
197 "url": "https://github.com/iliakan/detect-node"
198 },
199 "keywords": [
200 "detect",
201 "node"
202 ],
203 "author": {
204 "name": "Ilya Kantor"
205 },
206 "license": "ISC",
207 "bugs": {
208 "url": "https://github.com/iliakan/detect-node/issues"
209 },
210 "homepage": "https://github.com/iliakan/detect-node",
211 "gitHead": "4837fa0620d2e8db948a718a8b5f89a8073c8ff4",
212 "_id": "[email protected]",
213 "_shasum": "a2033c09cc8e158d37748fbde7507832bd6ce127",
214 "_from": ".",
215 "_npmVersion": "1.4.21",
216 "_npmUser": {
217 "name": "iliakan",
218 "email": "[email protected]"
219 },
220 "maintainers": [
221 {
222 "name": "iliakan",
223 "email": "[email protected]"
224 }
225 ],
226 "dist": {
227 "shasum": "a2033c09cc8e158d37748fbde7507832bd6ce127",
228 "tarball": "https://registry.npmjs.org/detect-node/-/detect-node-2.0.3.tgz"
229 },
230 "directories": {}
231 },
232 "2.0.4": {
233 "name": "detect-node",
234 "version": "2.0.4",
235 "description": "Detect Node.JS (as opposite to browser environment) (reliable)",
236 "main": "index.js",
237 "browser": "browser.js",
238 "scripts": {
239 "test": "echo \"Error: no test specified\" && exit 1"
240 },
241 "repository": {
242 "type": "git",
243 "url": "git+https://github.com/iliakan/detect-node.git"
244 },
245 "keywords": [
246 "detect",
247 "node"
248 ],
249 "author": {
250 "name": "Ilya Kantor"
251 },
252 "license": "ISC",
253 "bugs": {
254 "url": "https://github.com/iliakan/detect-node/issues"
255 },
256 "homepage": "https://github.com/iliakan/detect-node",
257 "gitHead": "563e0b838ec1dd9b169d843268cdb220b78ddd91",
258 "_id": "[email protected]",
259 "_npmVersion": "6.4.0",
260 "_nodeVersion": "10.9.0",
261 "_npmUser": {
262 "name": "iliakan",
263 "email": "[email protected]"
264 },
265 "dist": {
266 "integrity": "sha512-ZIzRpLJrOj7jjP2miAtgqIfmzbxa4ZOr5jJc601zklsfEx9oTzmmj2nVpIPRpNlRTIh8lc1kyViIY7BWSGNmKw==",
267 "shasum": "014ee8f8f669c5c58023da64b8179c083a28c46c",
268 "tarball": "https://registry.npmjs.org/detect-node/-/detect-node-2.0.4.tgz",
269 "fileCount": 5,
270 "unpackedSize": 2549,
271 "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbiWQ3CRA9TVsSAnZWagAAMrwQAJUWqhr3R8fUX9E2H04D\nNcoFtX6tYlFDUWz7AegYBpyj8E2c85Osf16LOM/WCAYhusmIw0kkEfd1suU2\nw7tXK+hQeDvQvhh5WGXqT88fI6UY33ryXHK4/J6QX5k1AXMO4jm74EQ8hXCs\nINjy6O+DC2CEni+CgUgxxU1CmIABcRGaB7WIwFOuwlgaHo7QRUnVnpqeZ6ZN\n7RpVE+3ucJjvCW1s5d/6pLYiRoRZIfudBMRD9OYkdvFGzQ71BKo7AhPQa4Bz\n5w8g3i0UQ6sx7RSYrWNeXRlrAD798fwvGtXsUwIkUE9QJzfT+k5jdHS/aFJT\n3cIIq4+jwV9ODJkkGxmILaWRpuBLpHI+syh3/Xmb113bB1QpcLij1BXJS8sN\ncR1xnLlD72CuFYuAeDkxsTk47D+mK0IDVWa9HgDi8D7IqBSwNOZLW1tuddql\nThwQWn6KIzzCzMKlBajt0rqyIUt5J4kLVXVS7wKvJRQhyaCrguFrdE4jbsjy\npCoqBydwvtrBnLlydr0WbNE94xoLPudJPlxjnyWrAd/MmjvI3RfhAAM+oQkE\n6s00+x2fx2cT51wjX/w+STN5CvNLGZerpTM0xgZmztwB2aWUVBybvAxdtW4F\nhaIf21JXHvTl5F8UXqKHD4dv6mB1w9X1ZcDYZ/hxetoj70xhevfvmFGZ3mVs\n6W0B\r\n=HQIg\r\n-----END PGP SIGNATURE-----\r\n"
272 },
273 "maintainers": [
274 {
275 "name": "iliakan",
276 "email": "[email protected]"
277 }
278 ],
279 "directories": {},
280 "_npmOperationalInternal": {
281 "host": "s3://npm-registry-packages",
282 "tmp": "tmp/detect-node_2.0.4_1535730743130_0.9044559921683464"
283 },
284 "_hasShrinkwrap": false
285 }
286 },
287 "readme": "### Install\n\n```shell\nnpm install --save detect-node\n```\n\n### Usage:\n\n```js\nvar isNode = require('detect-node');\n\nif (isNode) {\n console.log(\"Running under Node.JS\");\n} else {\n alert(\"Hello from browser (or whatever not-a-node env)\");\n}\n```\n\nThe check is performed as:\n```js\nmodule.exports = false;\n\n// Only Node.JS has a process variable that is of [[Class]] process\ntry {\n module.exports = Object.prototype.toString.call(global.process) === '[object process]' \n} catch(e) {}\n\n```\n\nThanks to Ingvar Stepanyan for the initial idea. This check is both **the most reliable I could find** and it does not use `process` env directly, which would cause browserify to include it into the build.\n",
288 "maintainers": [
289 {
290 "name": "iliakan",
291 "email": "[email protected]"
292 }
293 ],
294 "time": {
295 "modified": "2019-01-02T21:18:08.875Z",
296 "created": "2014-07-31T10:20:21.252Z",
297 "1.0.0": "2014-07-31T10:20:21.252Z",
298 "2.0.0": "2014-07-31T10:30:55.255Z",
299 "2.0.1": "2014-07-31T10:34:58.862Z",
300 "2.0.2": "2014-07-31T10:36:39.833Z",
301 "2.0.3": "2014-08-01T16:28:40.851Z",
302 "2.0.4": "2018-08-31T15:52:23.291Z"
303 },
304 "homepage": "https://github.com/iliakan/detect-node",
305 "keywords": [
306 "detect",
307 "node"
308 ],
309 "repository": {
310 "type": "git",
311 "url": "git+https://github.com/iliakan/detect-node.git"
312 },
313 "author": {
314 "name": "Ilya Kantor"
315 },
316 "bugs": {
317 "url": "https://github.com/iliakan/detect-node/issues"
318 },
319 "license": "ISC",
320 "readmeFilename": "Readme.md",
321 "users": {
322 "xch": true,
323 "i-erokhin": true,
324 "cliff": true
325 }
326 }