/** * @param {string} data */ dataAdded(data) { if (data.startsWith('Debugger listening on') || data.startsWith('Debugger attached.') || data.startsWith('Waiting for the debugger to disconnect...')) return; this._terminal.write(data); }
fs.readFileSync(gitignorePath, "utf8") .split(/\r?\n/) .map((sourceLine) => { sourceLine = sourceLine.trim() if (sourceLine !== "") { return sourceLine.startsWith("/") ? sourceLine.slice(1) : "**/" + sourceLine } return sourceLine }) .filter(Boolean)
next() { let init = this.initial != null ? String(this.initial) : ''; if (!init || !init.startsWith(this.input)) return this.alert(); this.input = this.initial; this.cursor = this.initial.length; this.render(); }
const isInternalImport = node => { let source = ''; if (node.type === 'Variable') { source = node.node.init.arguments[0].value; } else if (node.type === 'ImportBinding') { source = node.parent.source.value; } return ( !source.includes('node_modules') && (source.startsWith('.') || source.startsWith('/')) ); }
/** * @override * @param {string} path * @param {?string} name * @return {!Promise<?string>} */ async createFile(path, name) { const result = await this._fsIOService.createFile(this._rootURL + (path.length === 0 || path.startsWith('/') ? '' : '/') + path); return result.substr(this._rootURL.length + 1); }
let namespaceCompletion = (prefix) => { return Object.keys(namespaces) .filter(n => n.startsWith(prefix) && n !== prefix) .map(n => ({suggestion: n, type:'namespace'})); }
function isExternalLink (string) { if ( config.siteUrl && String(string).startsWith(config.siteUrl) ) { return false } return externalRE.test(string) }
Object.defineProperty(o,"baseUrl",{ get:function () { let url=sessionStorage.getItem("baseUrl") return (url && url.startsWith("http://"))?url:"http://"+url; }, enumerable : true, configurable : true })
/** * Whether or not this attachment has been marked as a spoiler * @type {boolean} * @readonly */ get spoiler() { return Util.basename(this.url).startsWith('SPOILER_'); }
normalizeFields (fields) { const res = {} for (const key in fields) { if (key.startsWith('_')) continue // skip links and embeds etc res[camelCase(key)] = this.normalizeFieldValue(fields[key]) } return res }
function prependSlash(slash = '') { if (slash.startsWith('/')) { return slash; } return `/${slash}`; }
/** * Checks if an import is a bare import (it doesn't start with with . or /) * * @param {object} importedModule A node representing the dependency being imported * @param {string} importedModule.value Name of the imported module */ const isBareImport = ( { value } ) => { return ! value.startsWith( '.' ) && ! value.startsWith( '/' ); }
function prependSlash(slash = '') { if (slash.startsWith('/')) { return slash; } return `/${slash}`; }
function isExternalLink (string) { if ( config.siteUrl && String(string).startsWith(config.siteUrl) ) { return false } return externalRE.test(string) }
Object.defineProperty(o,"host",{ get:function () { let url=sessionStorage.getItem("baseUrl") return (url && url.startsWith("http://"))?url:"http://"+url; }, enumerable : true, configurable : true })