MCPcopy Create free account
hub / github.com/kpdecker/jsdiff / removeEmpty

Method removeEmpty

src/diff/base.ts:275–283  ·  view source on GitHub ↗
(array: TokenT[])

Source from the content-addressed store, hash-verified

273 }
274
275 removeEmpty(array: TokenT[]): TokenT[] {
276 const ret: TokenT[] = [];
277 for (let i = 0; i < array.length; i++) {
278 if (array[i]) {
279 ret.push(array[i]);
280 }
281 }
282 return ret;
283 }
284
285 // eslint-disable-next-line @typescript-eslint/no-unused-vars
286 castInput(value: InputValueT, options: AllDiffOptions): ValueT {

Callers 2

diffMethod · 0.95
sentence.jsFile · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected