MCPcopy Create free account
hub / github.com/ChromeDevTools/devtools-frontend / startsTheSame

Function startsTheSame

scripts/javascript_natives/helpers.js:162–170  ·  view source on GitHub ↗
(smaller, bigger)

Source from the content-addressed store, hash-verified

160 }
161
162 function startsTheSame(smaller, bigger) {
163 for (let i = 0; i < smaller.length; i++) {
164 const withoutQuestion = str => /[\?]?(.*)/.exec(str)[1];
165 if (withoutQuestion(smaller[i]) !== withoutQuestion(bigger[i])) {
166 return false;
167 }
168 }
169 return true;
170 }
171
172 methods.get(name).set(parent, filteredSignatures);
173 jsonParents.add(JSON.stringify(filteredSignatures));

Callers 1

postProcessFunction · 0.85

Calls 1

withoutQuestionFunction · 0.85

Tested by

no test coverage detected