text stringlengths 9 39.2M | dir stringlengths 26 295 | lang stringclasses 185
values | created_date timestamp[us] | updated_date timestamp[us] | repo_name stringlengths 1 97 | repo_full_name stringlengths 7 106 | star int64 1k 183k | len_tokens int64 1 13.8M |
|---|---|---|---|---|---|---|---|---|
```javascript
//.CommonJS
var CSSOM = {};
///CommonJS
/**
* @constructor
* @see path_to_url#the-cssrule-interface
* @see path_to_url#CSS-CSSRule
*/
CSSOM.CSSRule = function CSSRule() {
this.parentRule = null;
this.parentStyleSheet = null;
};
CSSOM.CSSRule.UNKNOWN_RULE = 0; // obsolete
CSSOM.CSS... | /content/code_sandbox/node_modules/cssom/lib/CSSRule.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 305 |
```javascript
//.CommonJS
var CSSOM = {
CSSRule: require("./CSSRule").CSSRule,
};
///CommonJS
/**
* @constructor
* @see path_to_url#the-csssupportsrule-interface
*/
CSSOM.CSSSupportsRule = function CSSSupportsRule() {
CSSOM.CSSRule.call(this);
this.conditionText = '';
this.cssRules = [];
};
CSSOM.CSSSuppo... | /content/code_sandbox/node_modules/cssom/lib/CSSSupportsRule.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 236 |
```javascript
//.CommonJS
var CSSOM = {};
///CommonJS
/**
* @param {string} token
*/
CSSOM.parse = function parse(token) {
var i = 0;
/**
"before-selector" or
"selector" or
"atRule" or
"atBlock" or
"conditionBlock" or
"before-name" or
"name" or
"before-value" or
"value"
*/
var state = "befor... | /content/code_sandbox/node_modules/cssom/lib/parse.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 3,190 |
```javascript
//.CommonJS
var CSSOM = {
CSSStyleDeclaration: require("./CSSStyleDeclaration").CSSStyleDeclaration,
CSSRule: require("./CSSRule").CSSRule
};
///CommonJS
/**
* @constructor
* @see path_to_url#css-font-face-rule
*/
CSSOM.CSSFontFaceRule = function CSSFontFaceRule() {
CSSOM.CSSRule.call(this);
this... | /content/code_sandbox/node_modules/cssom/lib/CSSFontFaceRule.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 245 |
```javascript
//.CommonJS
var CSSOM = {};
///CommonJS
/**
* @constructor
* @see path_to_url#the-medialist-interface
*/
CSSOM.MediaList = function MediaList(){
this.length = 0;
};
CSSOM.MediaList.prototype = {
constructor: CSSOM.MediaList,
/**
* @return {string}
*/
get mediaText() {
return Array.protot... | /content/code_sandbox/node_modules/cssom/lib/MediaList.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 290 |
```javascript
//.CommonJS
var CSSOM = {
CSSRule: require("./CSSRule").CSSRule
};
///CommonJS
/**
* @constructor
* @see path_to_url#host-at-rule
*/
CSSOM.CSSHostRule = function CSSHostRule() {
CSSOM.CSSRule.call(this);
this.cssRules = [];
};
CSSOM.CSSHostRule.prototype = new CSSOM.CSSRule();
CSSOM.CSSHostRule.p... | /content/code_sandbox/node_modules/cssom/lib/CSSHostRule.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 246 |
```javascript
//.CommonJS
var CSSOM = {};
///CommonJS
/**
* @constructor
* @see path_to_url
*/
CSSOM.MatcherList = function MatcherList(){
this.length = 0;
};
CSSOM.MatcherList.prototype = {
constructor: CSSOM.MatcherList,
/**
* @return {string}
*/
get matcherText() {
return Ar... | /content/code_sandbox/node_modules/cssom/lib/MatcherList.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 313 |
```javascript
//.CommonJS
var CSSOM = {
CSSRule: require("./CSSRule").CSSRule,
CSSStyleSheet: require("./CSSStyleSheet").CSSStyleSheet,
MediaList: require("./MediaList").MediaList
};
///CommonJS
/**
* @constructor
* @see path_to_url#cssimportrule
* @see path_to_url#CSS-CSSImportRule
*/
CSSOM.CSSImportRule = fu... | /content/code_sandbox/node_modules/cssom/lib/CSSImportRule.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 795 |
```javascript
//.CommonJS
var CSSOM = {
CSSStyleDeclaration: require("./CSSStyleDeclaration").CSSStyleDeclaration,
CSSRule: require("./CSSRule").CSSRule
};
///CommonJS
/**
* @constructor
* @see path_to_url#cssstylerule
* @see path_to_url#CSS-CSSStyleRule
*/
CSSOM.CSSStyleRule = function CSSStyleRule() {
CSSOM.... | /content/code_sandbox/node_modules/cssom/lib/CSSStyleRule.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,031 |
```javascript
var CSSOM = {};
``` | /content/code_sandbox/node_modules/cssom/lib/CSSOM.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 7 |
```javascript
//.CommonJS
var CSSOM = {};
///CommonJS
/**
* @constructor
* @see path_to_url#the-stylesheet-interface
*/
CSSOM.StyleSheet = function StyleSheet() {
this.parentStyleSheet = null;
};
//.CommonJS
exports.StyleSheet = CSSOM.StyleSheet;
///CommonJS
``` | /content/code_sandbox/node_modules/cssom/lib/StyleSheet.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 67 |
```javascript
//.CommonJS
var CSSOM = {
CSSValue: require('./CSSValue').CSSValue
};
///CommonJS
/**
* @constructor
* @see path_to_url
*
*/
CSSOM.CSSValueExpression = function CSSValueExpression(token, idx) {
this._token = token;
this._idx = idx;
};
CSSOM.CSSValueExpression.prototype = new CSSOM.CSSValue();
CS... | /content/code_sandbox/node_modules/cssom/lib/CSSValueExpression.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,635 |
```javascript
'use strict'
var net = require('net')
, tls = require('tls')
, http = require('http')
, https = require('https')
, events = require('events')
, assert = require('assert')
, util = require('util')
, Buffer = require('safe-buffer').Buffer
;
exports.httpOverHttp = httpOverHttp
exports.https... | /content/code_sandbox/node_modules/tunnel-agent/index.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,705 |
```javascript
/*
* All rights reserved.
*
* nwmatcher-noqsa.js - A fast CSS selector engine and matcher
*
* Author: Diego Perini <diego.perini at gmail com>
* Version: 1.4.4
* Created: 20070722
* Release: 20180305
*
* path_to_url
* Download:
* path_to_url
*/
(function(global, factory) {
if (typeof mo... | /content/code_sandbox/node_modules/nwmatcher/src/nwmatcher-noqsa.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 8,849 |
```javascript
/*
* All rights reserved.
*
* nwmatcher.js - A fast CSS selector engine and matcher
*
* Author: Diego Perini <diego.perini at gmail com>
* Version: 1.4.4
* Created: 20070722
* Release: 20180305
*
* path_to_url
* Download:
* path_to_url
*/
(function(global, factory) {
if (typeof module =... | /content/code_sandbox/node_modules/nwmatcher/src/nwmatcher.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 15,524 |
```javascript
/*
* All rights reserved.
*
* nwmatcher-base.js - A fast CSS selector engine and matcher
*
* Author: Diego Perini <diego.perini at gmail com>
* Version: 1.4.4
* Created: 20070722
* Release: 20180305
*
* path_to_url
* Download:
* path_to_url
*/
(function(global, factory) {
if (typeof mod... | /content/code_sandbox/node_modules/nwmatcher/src/nwmatcher-base.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 6,709 |
```javascript
/*
* All rights reserved.
*
* this is just a small example to show
* how an extension for NWMatcher could be
* adapted to handle special jQuery selectors
*
* Child Selectors
* :even, :odd, :eq, :lt, :gt, :first, :last, :nth
*
* Pseudo Selectors
* :has, :button, :header, :input, :checkbox, :radi... | /content/code_sandbox/node_modules/nwmatcher/src/modules/nwmatcher-jquery.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,004 |
```javascript
/*
* All rights reserved.
*
* this is just a small example to show
* how an extension for NWMatcher could be
* adapted to handle WebForms/HTML5 selectors
*
* Pseudo Selectors
* :default, :indeterminate, :optional, :required,
* :valid, :invalid, :in-range, :out-of-range,
* :read-only, :read-write... | /content/code_sandbox/node_modules/nwmatcher/src/modules/nwmatcher-webforms.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 892 |
```javascript
/*
* All rights reserved.
*
* Caching/memoization module for NWMatcher
*
* Added capabilities:
*
* - Mutation Events are feature tested and used safely
* - handle caching different document types HTML/XML/SVG
* - store result sets for different selectors / contexts
* - simultaneously control mut... | /content/code_sandbox/node_modules/nwmatcher/src/modules/nwmatcher-cache.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,198 |
```javascript
NW.Dom.shortcuts = (function() {
// match missing R/L context
var nextID = 0,
reLeftContext = /^[\x20\t\n\r\f]*[>+~]/,
reRightContext = /[>+~][\x20\t\n\r\f]*$/;
return function(selector, from, alt) {
// add left context if missing
if (reLeftContext.test(selector)) {
if (from.nod... | /content/code_sandbox/node_modules/nwmatcher/src/modules/nwmatcher-shortcuts.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 269 |
```javascript
/*
* All rights reserved.
*
* CSS3 pseudo-classes extension for NWMatcher
*
* Added capabilities:
*
* - structural pseudo-classes
*
* :root, :empty,
* :nth-child(), nth-of-type(),
* :nth-last-child(), nth-last-of-type(),
* :first-child, :last-child, :only-child
* :first-of-type, :last-of-type... | /content/code_sandbox/node_modules/nwmatcher/src/modules/nwmatcher-pseudos.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 2,583 |
```javascript
/*
* Element Traversal methods from Juriy Zaytsev (kangax)
* used to emulate Prototype up/down/previous/next methods
*/
(function(D){
// TODO: all of this needs tests
var match = D.match, select = D.select, root = document.documentElement,
// Use the Element Traversal API if available.
nextE... | /content/code_sandbox/node_modules/nwmatcher/src/modules/nwmatcher-traversal.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 700 |
```javascript
/* eslint no-console: "off" */
var asynckit = require('./')
, async = require('async')
, assert = require('assert')
, expected = 0
;
var Benchmark = require('benchmark');
var suite = new Benchmark.Suite;
var source = [];
for (var z = 1; z < 100; z++)
{
source.push(z);
expected += z;
}
... | /content/code_sandbox/node_modules/asynckit/bench.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 344 |
```javascript
module.exports =
{
parallel : require('./parallel.js'),
serial : require('./serial.js'),
serialOrdered : require('./serialOrdered.js')
};
``` | /content/code_sandbox/node_modules/asynckit/index.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 34 |
```javascript
var iterate = require('./lib/iterate.js')
, initState = require('./lib/state.js')
, terminator = require('./lib/terminator.js')
;
// Public API
module.exports = parallel;
/**
* Runs iterator over provided array elements in parallel
*
* @param {array|object} list - array or object (named l... | /content/code_sandbox/node_modules/asynckit/parallel.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 241 |
```javascript
var serialOrdered = require('./serialOrdered.js');
// Public API
module.exports = serial;
/**
* Runs iterator over provided array elements in series
*
* @param {array|object} list - array or object (named list) to iterate over
* @param {function} iterator - iterator to run
* @param {function}... | /content/code_sandbox/node_modules/asynckit/serial.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 115 |
```javascript
var inherits = require('util').inherits
, Readable = require('stream').Readable
, ReadableAsyncKit = require('./lib/readable_asynckit.js')
, ReadableParallel = require('./lib/readable_parallel.js')
, ReadableSerial = require('./lib/readable_serial.js')
... | /content/code_sandbox/node_modules/asynckit/stream.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 164 |
```javascript
var iterate = require('./lib/iterate.js')
, initState = require('./lib/state.js')
, terminator = require('./lib/terminator.js')
;
// Public API
module.exports = serialOrdered;
// sorting helpers
module.exports.ascending = ascending;
module.exports.descending = descending;
/**
* Runs iterator... | /content/code_sandbox/node_modules/asynckit/serialOrdered.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 437 |
```javascript
// API
module.exports = abort;
/**
* Aborts leftover active jobs
*
* @param {object} state - current state object
*/
function abort(state)
{
Object.keys(state.jobs).forEach(clean.bind(state));
// reset leftover jobs
state.jobs = {};
}
/**
* Cleans up leftover job by invoking abort function f... | /content/code_sandbox/node_modules/asynckit/lib/abort.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 126 |
```javascript
var defer = require('./defer.js');
// API
module.exports = async;
/**
* Runs provided callback asynchronously
* even if callback itself is not
*
* @param {function} callback - callback to invoke
* @returns {function} - augmented callback
*/
function async(callback)
{
var isAsync = false;
//... | /content/code_sandbox/node_modules/asynckit/lib/async.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 141 |
```javascript
var parallel = require('../parallel.js');
// API
module.exports = ReadableParallel;
/**
* Streaming wrapper to `asynckit.parallel`
*
* @param {array|object} list - array or object (named list) to iterate over
* @param {function} iterator - iterator to run
* @param {function} callback - invoke... | /content/code_sandbox/node_modules/asynckit/lib/readable_parallel.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 164 |
```javascript
// API
module.exports = state;
/**
* Creates initial state object
* for iteration over list
*
* @param {array|object} list - list to iterate over
* @param {function|null} sortMethod - function to use for keys sort,
* or `null` to keep them as is
* @returns {... | /content/code_sandbox/node_modules/asynckit/lib/state.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 236 |
```javascript
var streamify = require('./streamify.js')
, defer = require('./defer.js')
;
// API
module.exports = ReadableAsyncKit;
/**
* Base constructor for all streams
* used to hold properties/methods
*/
function ReadableAsyncKit()
{
ReadableAsyncKit.super_.apply(this, arguments);
// list of activ... | /content/code_sandbox/node_modules/asynckit/lib/readable_asynckit.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 419 |
```javascript
module.exports = defer;
/**
* Runs provided function on next iteration of the event loop
*
* @param {function} fn - function to run
*/
function defer(fn)
{
var nextTick = typeof setImmediate == 'function'
? setImmediate
: (
typeof process == 'object' && typeof process.nextTick == 'fun... | /content/code_sandbox/node_modules/asynckit/lib/defer.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 116 |
```javascript
var serialOrdered = require('../serialOrdered.js');
// API
module.exports = ReadableSerialOrdered;
// expose sort helpers
module.exports.ascending = serialOrdered.ascending;
module.exports.descending = serialOrdered.descending;
/**
* Streaming wrapper to `asynckit.serialOrdered`
*
* @param {array|... | /content/code_sandbox/node_modules/asynckit/lib/readable_serial_ordered.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 221 |
```javascript
var serial = require('../serial.js');
// API
module.exports = ReadableSerial;
/**
* Streaming wrapper to `asynckit.serial`
*
* @param {array|object} list - array or object (named list) to iterate over
* @param {function} iterator - iterator to run
* @param {function} callback - invoked when a... | /content/code_sandbox/node_modules/asynckit/lib/readable_serial.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 163 |
```javascript
var async = require('./async.js');
// API
module.exports = {
iterator: wrapIterator,
callback: wrapCallback
};
/**
* Wraps iterators with long signature
*
* @this ReadableAsyncKit#
* @param {function} iterator - function to wrap
* @returns {function} - wrapped function
*/
function wrapIte... | /content/code_sandbox/node_modules/asynckit/lib/streamify.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 724 |
```javascript
var abort = require('./abort.js')
, async = require('./async.js')
;
// API
module.exports = terminator;
/**
* Terminates jobs in the attached state context
*
* @this AsyncKitState#
* @param {function} callback - final callback to invoke after termination
*/
function terminator(callback)
{
if... | /content/code_sandbox/node_modules/asynckit/lib/terminator.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 129 |
```javascript
var async = require('./async.js')
, abort = require('./abort.js')
;
// API
module.exports = iterate;
/**
* Iterates over each job object
*
* @param {array|object} list - array or object (named list) to iterate over
* @param {function} iterator - iterator to run
* @param {object} state - current... | /content/code_sandbox/node_modules/asynckit/lib/iterate.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 445 |
```javascript
// Generated by LiveScript 1.2.0
(function(){
var reject, special, tokenRegex;
reject = require('prelude-ls').reject;
function consumeOp(tokens, op){
if (tokens[0] === op) {
return tokens.shift();
} else {
throw new Error("Expected '" + op + "', but got '" + tokens[0] + "' instea... | /content/code_sandbox/node_modules/levn/lib/parse.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 900 |
```javascript
// Generated by LiveScript 1.4.0
(function(){
var parseString, cast, parseType, VERSION, parsedTypeParse, parse;
parseString = require('./parse-string');
cast = require('./cast');
parseType = require('type-check').parseType;
VERSION = '0.3.0';
parsedTypeParse = function(parsedType, string, opt... | /content/code_sandbox/node_modules/levn/lib/index.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 194 |
```javascript
// Generated by LiveScript 1.4.0
(function(){
var reject, special, tokenRegex;
reject = require('prelude-ls').reject;
function consumeOp(tokens, op){
if (tokens[0] === op) {
return tokens.shift();
} else {
throw new Error("Expected '" + op + "', but got '" + tokens[0] + "' instea... | /content/code_sandbox/node_modules/levn/lib/parse-string.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,054 |
```javascript
// Generated by LiveScript 1.4.0
(function(){
var parsedTypeCheck, types, toString$ = {}.toString;
parsedTypeCheck = require('type-check').parsedTypeCheck;
types = {
'*': function(value, options){
switch (toString$.call(value).slice(8, -1)) {
case 'Array':
return typeCast(val... | /content/code_sandbox/node_modules/levn/lib/cast.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,825 |
```javascript
var fs = require("fs");
var zlib = require("zlib");
var fd_slicer = require("fd-slicer");
var util = require("util");
var EventEmitter = require("events").EventEmitter;
var Transform = require("stream").Transform;
var PassThrough = require("stream").PassThrough;
var Writable = require("stream").Writable;
... | /content/code_sandbox/node_modules/yauzl/index.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 6,280 |
```javascript
// Generated by LiveScript 1.2.0
(function(){
var parsedTypeCheck, types, toString$ = {}.toString;
parsedTypeCheck = require('type-check').parsedTypeCheck;
types = {
'*': function(it){
switch (toString$.call(it).slice(8, -1)) {
case 'Array':
return coerceType(it, {
... | /content/code_sandbox/node_modules/levn/lib/coerce.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,641 |
```javascript
/*
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistribut... | /content/code_sandbox/node_modules/estraverse/gulpfile.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 617 |
```javascript
'use strict';
/* eslint-disable sort-keys */
module.exports = Object.freeze({
// same as DOM DOCUMENT_POSITION_
DISCONNECTED: 1,
PRECEDING: 2,
FOLLOWING: 4,
CONTAINS: 8,
CONTAINED_BY: 16,
});
``` | /content/code_sandbox/node_modules/symbol-tree/lib/TreePosition.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 63 |
```javascript
'use strict';
const TREE = Symbol();
const ROOT = Symbol();
const NEXT = Symbol();
const ITERATE_FUNC = Symbol();
class TreeIterator {
constructor(tree, root, firstResult, iterateFunction) {
this[TREE] = tree;
this[ROOT] = root;
this[NEXT] = firstR... | /content/code_sandbox/node_modules/symbol-tree/lib/TreeIterator.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 391 |
```javascript
/*
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistribut... | /content/code_sandbox/node_modules/estraverse/estraverse.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 5,428 |
```javascript
'use strict';
module.exports = class SymbolTreeNode {
constructor() {
this.parent = null;
this.previousSibling = null;
this.nextSibling = null;
this.firstChild = null;
this.lastChild = null;
/** This... | /content/code_sandbox/node_modules/symbol-tree/lib/SymbolTreeNode.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 348 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
var path = require('path');
var fs = require('fs');
var copy = require('dryice').copy;
function removeAmdefine(src) {
src = String(src).replace(
/if\s*\(typeof\s*define\s*!==\s*'function'\)\s*{\s*var\s*define\s*=\s*require\('amdefine... | /content/code_sandbox/node_modules/source-map/Makefile.dryice.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,010 |
```javascript
/*
* path_to_url
*/
exports.SourceMapGenerator = require('./source-map/source-map-generator').SourceMapGenerator;
exports.SourceMapConsumer = require('./source-map/source-map-consumer').SourceMapConsumer;
exports.SourceNode = require('./source-map/source-node').SourceNode;
``` | /content/code_sandbox/node_modules/source-map/lib/source-map.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 57 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
/**
* Recursive implementation of binary search.
*
* @param aLow Indices here and lower do... | /content/code_sandbox/node_modules/source-map/lib/source-map/binary-search.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 805 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*
* Based on the Base 64 VLQ implementation in Closure Compiler:
* path_to_url
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* ... | /content/code_sandbox/node_modules/source-map/lib/source-map/base64-vlq.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,195 |
```javascript
'use strict';
/**
* @module symbol-tree
* @author Joris van der Wel <joris@jorisvanderwel.com>
*/
const SymbolTreeNode = require('./SymbolTreeNode');
const TreePosition = require('./TreePosition');
const TreeIterator = require('./TreeIterator');
function returnTrue() {
return true;
}
functi... | /content/code_sandbox/node_modules/symbol-tree/lib/SymbolTree.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 5,688 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var base64VLQ = require('./base64-vlq');
var util = require('./util');
var ArraySet = require('... | /content/code_sandbox/node_modules/source-map/lib/source-map/source-map-generator.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 2,829 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var util = require('./util');
/**
* A data structure which is a combination of an array and a... | /content/code_sandbox/node_modules/source-map/lib/source-map/array-set.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 666 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var SourceMapGenerator = require('./source-map-generator').SourceMapGenerator;
var util = require... | /content/code_sandbox/node_modules/source-map/lib/source-map/source-node.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 2,776 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var charToIntMap = {};
var intToCharMap = {};
'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstu... | /content/code_sandbox/node_modules/source-map/lib/source-map/base64.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 269 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
/**
* This is a helper function for getting values from parameter/options
* objects.
*
... | /content/code_sandbox/node_modules/source-map/lib/source-map/util.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,358 |
```javascript
#!/usr/bin/env node
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
var assert = require('assert');
var fs = require('fs');
var path = require('path');
var util = require('./source-map/util');
function run(tests) {
var failures = [];
var total = 0;
var passed = 0;
for (var i = ... | /content/code_sandbox/node_modules/source-map/test/run-tests.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 377 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var ArraySet = require('../../lib/source-map/array-set').ArraySet;
function makeTestSet() {
... | /content/code_sandbox/node_modules/source-map/test/source-map/test-array-set.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 820 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var util = require('./util');
var binarySearch = require('./binary-search');
var ArraySet = req... | /content/code_sandbox/node_modules/source-map/lib/source-map/source-map-consumer.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 3,879 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var binarySearch = require('../../lib/source-map/binary-search');
function numberCompare(a, b) {... | /content/code_sandbox/node_modules/source-map/test/source-map/test-binary-search.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 397 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var base64VLQ = require('../../lib/source-map/base64-vlq');
exports['test normal encoding and de... | /content/code_sandbox/node_modules/source-map/test/source-map/test-base64-vlq.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 152 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var SourceMapGenerator = require('../../lib/source-map/source-map-generator').SourceMapGenerator;
... | /content/code_sandbox/node_modules/source-map/test/source-map/test-source-map-generator.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 3,278 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var base64 = require('../../lib/source-map/base64');
exports['test out of range encoding'] = fun... | /content/code_sandbox/node_modules/source-map/test/source-map/test-base64.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 206 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var SourceMapConsumer = require('../../lib/source-map/source-map-consumer').SourceMapConsumer;
va... | /content/code_sandbox/node_modules/source-map/test/source-map/test-dog-fooding.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 893 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var util = require('../../lib/source-map/util');
// This is a test mapping which maps functions ... | /content/code_sandbox/node_modules/source-map/test/source-map/util.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,375 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var sourceMap;
try {
sourceMap = require('../../lib/source-map');
} catch (e) {
sourceM... | /content/code_sandbox/node_modules/source-map/test/source-map/test-api.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 171 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var SourceMapGenerator = require('../../lib/source-map/source-map-generator').SourceMapGenerator;
... | /content/code_sandbox/node_modules/source-map/test/source-map/test-source-node.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 3,175 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
/*
* WARNING!
*
* Do not edit this file directly, it is built from the sources at
* path_to_url
*/
Components.utils.import('resource://gre/modules/devtools/Require.jsm');
Components.utils.import('resource://gre/modules/devtools/Sourc... | /content/code_sandbox/node_modules/source-map/build/prefix-utils.jsm | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 99 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
///////////////////////////////////////////////////////////////////////////////
this.sourceMap = {
SourceMapConsumer: require('source-map/source-map-consumer').SourceMapConsumer,
SourceMapGenerator: require('source-map/source-map-generator').SourceMapGenera... | /content/code_sandbox/node_modules/source-map/build/suffix-browser.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 73 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
/**
* Define a module along with a payload.
* @param {string} moduleName Name for the payload
* @param {ignored} deps Ignored. For compatibility with CommonJS AMD Spec
* @param {function} payload Function with (require, exports, module... | /content/code_sandbox/node_modules/source-map/build/mini-require.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 973 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
///////////////////////////////////////////////////////////////////////////////
this.SourceMapConsumer = require('source-map/source-map-consumer').SourceMapConsumer;
this.SourceMapGenerator = require('source-map/source-map-generator').SourceMapGenerator;
this.S... | /content/code_sandbox/node_modules/source-map/build/suffix-source-map.jsm | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 67 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
/*
* WARNING!
*
* Do not edit this file directly, it is built from the sources at
* path_to_url
*/
///////////////////////////////////////////////////////////////////////////////
this.EXPORTED_SYMBOLS = [ "SourceMapConsumer", "Sour... | /content/code_sandbox/node_modules/source-map/build/prefix-source-map.jsm | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 91 |
```javascript
function run_test() {
runSourceMapTests('{THIS_MODULE}', do_throw);
}
``` | /content/code_sandbox/node_modules/source-map/build/test-suffix.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 19 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
function runSourceMapTests(modName, do_throw) {
let mod = require(modName);
let assert = require('test/source-map/assert');
let util = require('test/source-map/util');
assert.init(do_throw);
for (let k in mod) {
if (/^test/.... | /content/code_sandbox/node_modules/source-map/build/suffix-utils.jsm | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 114 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
if (typeof define !== 'function') {
var define = require('amdefine')(module, require);
}
define(function (require, exports, module) {
var SourceMapConsumer = require('../../lib/source-map/source-map-consumer').SourceMapConsumer;
va... | /content/code_sandbox/node_modules/source-map/test/source-map/test-source-map-consumer.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 3,875 |
```javascript
/*
* WARNING!
*
* Do not edit this file directly, it is built from the sources at
* path_to_url
*/
Components.utils.import('resource://test/Utils.jsm');
``` | /content/code_sandbox/node_modules/source-map/build/test-prefix.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 40 |
```javascript
/* -*- Mode: js; js-indent-level: 2; -*- */
/*
* path_to_url
*/
define('test/source-map/assert', ['exports'], function (exports) {
let do_throw = function (msg) {
throw new Error(msg);
};
exports.init = function (throw_fn) {
do_throw = throw_fn;
};
exports.doesNotThrow = function (f... | /content/code_sandbox/node_modules/source-map/build/assert-shim.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 290 |
```javascript
'use strict';
if (!process.version ||
process.version.indexOf('v0.') === 0 ||
process.version.indexOf('v1.') === 0 && process.version.indexOf('v1.8.') !== 0) {
module.exports = { nextTick: nextTick };
} else {
module.exports = process
}
function nextTick(fn, arg1, arg2, arg3) {
if (typeof ... | /content/code_sandbox/node_modules/process-nextick-args/index.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 291 |
```javascript
'use strict'
// A linked list to keep track of recently-used-ness
const Yallist = require('yallist')
const MAX = Symbol('max')
const LENGTH = Symbol('length')
const LENGTH_CALCULATOR = Symbol('lengthCalculator')
const ALLOW_STALE = Symbol('allowStale')
const MAX_AGE = Symbol('maxAge')
const DISPOSE = Sy... | /content/code_sandbox/node_modules/lru-cache/index.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 2,342 |
```javascript
'use strict';
require('core-js');
var inspect = require('./');
var test = require('tape');
test('Maps', function (t) {
t.equal(inspect(new Map([[1, 2]])), 'Map (1) {1 => 2}');
t.end();
});
test('WeakMaps', function (t) {
t.equal(inspect(new WeakMap([[{}, 2]])), 'WeakMap { ? }');
t.end(... | /content/code_sandbox/node_modules/object-inspect/test-core-js.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 175 |
```markdown
# object-inspect <sup>[![Version Badge][2]][1]</sup>
string representations of objects in node and the browser
[![github actions][actions-image]][actions-url]
[![coverage][codecov-image]][codecov-url]
[![dependency status][5]][6]
[![dev dependency status][7]][8]
[![Downloads][downloads-image]][downloads-u... | /content/code_sandbox/node_modules/object-inspect/readme.markdown | markdown | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 672 |
```javascript
module.exports = require('util').inspect;
``` | /content/code_sandbox/node_modules/object-inspect/util.inspect.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 10 |
```javascript
'use strict';
var inspect = require('../');
var Buffer = require('safer-buffer').Buffer;
var holes = ['a', 'b'];
holes[4] = 'e';
holes[6] = 'g';
var obj = {
a: 1,
b: [3, 4, undefined, null],
c: undefined,
d: null,
e: {
regex: /^x/i,
buf: Buffer.from('abc'),
h... | /content/code_sandbox/node_modules/object-inspect/example/all.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 123 |
```javascript
'use strict';
var inspect = require('../');
var obj = [1, 2, function f(n) { return n + 5; }, 4];
console.log(inspect(obj));
``` | /content/code_sandbox/node_modules/object-inspect/example/fn.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 40 |
```javascript
'use strict';
/* eslint-env browser */
var inspect = require('../');
var d = document.createElement('div');
d.setAttribute('id', 'beep');
d.innerHTML = '<b>wooo</b><i>iiiii</i>';
console.log(inspect([d, { a: 3, b: 4, c: [5, 6, [7, [8, [9]]]] }]));
``` | /content/code_sandbox/node_modules/object-inspect/example/inspect.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 88 |
```javascript
'use strict';
var inspect = require('../');
var obj = { a: 1, b: [3, 4] };
obj.c = obj;
console.log(inspect(obj));
``` | /content/code_sandbox/node_modules/object-inspect/example/circular.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 39 |
```javascript
'use strict';
var inspect = require('../');
var test = require('tape');
test('quoteStyle option', function (t) {
t['throws'](function () { inspect(null, { quoteStyle: false }); }, 'false is not a valid value');
t['throws'](function () { inspect(null, { quoteStyle: true }); }, 'true is not a vali... | /content/code_sandbox/node_modules/object-inspect/test/quoteStyle.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 244 |
```javascript
var test = require('tape');
var forEach = require('for-each');
var inspect = require('../');
test('bad indent options', function (t) {
forEach([
undefined,
true,
false,
-1,
1.2,
Infinity,
-Infinity,
NaN
], function (indent) {
... | /content/code_sandbox/node_modules/object-inspect/test/indent-option.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 2,040 |
```javascript
var hasMap = typeof Map === 'function' && Map.prototype;
var mapSizeDescriptor = Object.getOwnPropertyDescriptor && hasMap ? Object.getOwnPropertyDescriptor(Map.prototype, 'size') : null;
var mapSize = hasMap && mapSizeDescriptor && typeof mapSizeDescriptor.get === 'function' ? mapSizeDescriptor.get : nul... | /content/code_sandbox/node_modules/object-inspect/index.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 4,781 |
```javascript
var test = require('tape');
var inspect = require('../');
var xs = ['a', 'b'];
xs[5] = 'f';
xs[7] = 'j';
xs[8] = 'k';
test('holes', function (t) {
t.plan(1);
t.equal(
inspect(xs),
"[ 'a', 'b', , , , 'f', , 'j', 'k' ]"
);
});
``` | /content/code_sandbox/node_modules/object-inspect/test/holes.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 96 |
```javascript
'use strict';
var inspect = require('../');
var test = require('tape');
var mockProperty = require('mock-property');
test('when Object#hasOwnProperty is deleted', function (t) {
t.plan(1);
var arr = [1, , 3]; // eslint-disable-line no-sparse-arrays
t.teardown(mockProperty(Array.prototype, 1... | /content/code_sandbox/node_modules/object-inspect/test/has.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 138 |
```javascript
var test = require('tape');
var inspect = require('../');
var obj = { x: 'a\r\nb', y: '\x05! \x1f \x12' };
test('interpolate low bytes', function (t) {
t.plan(1);
t.equal(
inspect(obj),
"{ x: 'a\\r\\nb', y: '\\x05! \\x1F \\x12' }"
);
});
``` | /content/code_sandbox/node_modules/object-inspect/test/lowbyte.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 97 |
```javascript
'use strict';
var inspect = require('../');
var test = require('tape');
var hasToStringTag = require('has-tostringtag/shams')();
test('bigint', { skip: typeof BigInt === 'undefined' }, function (t) {
t.test('primitives', function (st) {
st.plan(3);
st.equal(inspect(BigInt(-256)), '-... | /content/code_sandbox/node_modules/object-inspect/test/bigint.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 565 |
```javascript
var inspect = require('../');
var test = require('tape');
var arrow = require('make-arrow-function')();
var functionsHaveConfigurableNames = require('functions-have-names').functionsHaveConfigurableNames();
test('function', function (t) {
t.plan(1);
var obj = [1, 2, function f(n) { return n; }, 4... | /content/code_sandbox/node_modules/object-inspect/test/fn.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 599 |
```javascript
var inspect = require('../');
var test = require('tape');
test('element', function (t) {
t.plan(3);
var elem = {
nodeName: 'div',
attributes: [{ name: 'class', value: 'row' }],
getAttribute: function (key) { return key; },
childNodes: []
};
var obj = [1, el... | /content/code_sandbox/node_modules/object-inspect/test/element.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 454 |
```javascript
'use strict';
var inspect = require('../');
var test = require('tape');
var mockProperty = require('mock-property');
var hasSymbols = require('has-symbols/shams')();
var hasToStringTag = require('has-tostringtag/shams')();
test('values', function (t) {
t.plan(1);
var obj = [{}, [], { 'a-b': 5 }]... | /content/code_sandbox/node_modules/object-inspect/test/values.js | javascript | 2016-03-11T09:28:00 | 2024-08-16T17:55:54 | antSword | AntSwordProject/antSword | 3,579 | 1,971 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.