MCPcopy
hub / github.com/mathuo/dockview / range

Function range

packages/dockview-core/src/math.ts:17–36  ·  view source on GitHub ↗
(from: number, to?: number)

Source from the content-addressed store, hash-verified

15};
16
17export const range = (from: number, to?: number): number[] => {
18 const result: number[] = [];
19
20 if (typeof to !== 'number') {
21 to = from;
22 from = 0;
23 }
24
25 if (from <= to) {
26 for (let i = from; i < to; i++) {
27 result.push(i);
28 }
29 } else {
30 for (let i = from; i > to; i--) {
31 result.push(i);
32 }
33 }
34
35 return result;
36};

Callers 9

resizeViewMethod · 0.90
onDidChangeMethod · 0.90
onPointerStartMethod · 0.90
distributeViewSizesMethod · 0.90
layoutMethod · 0.90
distributeEmptySpaceMethod · 0.90
updateSashEnablementMethod · 0.90
SplitviewClass · 0.90
math.spec.tsFile · 0.90

Calls 1

pushMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…