MCPcopy Index your code
hub / github.com/debug-js/debug / enabled

Function enabled

src/common.js:249–263  ·  view source on GitHub ↗

* Returns true if the given mode name is enabled, false otherwise. * * @param {String} name * @return {Boolean} * @api public

(name)

Source from the content-addressed store, hash-verified

247 * @api public
248 */
249 function enabled(name) {
250 for (const skip of createDebug.skips) {
251 if (matchesTemplate(name, skip)) {
252 return false;
253 }
254 }
255
256 for (const ns of createDebug.names) {
257 if (matchesTemplate(name, ns)) {
258 return true;
259 }
260 }
261
262 return false;
263 }
264
265 /**
266 * Coerce `val`.

Callers

nothing calls this directly

Calls 1

matchesTemplateFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…