MCPcopy Create free account
hub / github.com/heygen-com/hyperframes / stripComment

Function stripComment

packages/core/src/colorLuts.ts:35–43  ·  view source on GitHub ↗
(line: string)

Source from the content-addressed store, hash-verified

33const DEFAULT_MAX_SIZE = 64;
34
35function stripComment(line: string): string {
36 let inQuote = false;
37 for (let i = 0; i < line.length; i++) {
38 const char = line[i];
39 if (char === '"') inQuote = !inQuote;
40 if (char === "#" && !inQuote) return line.slice(0, i);
41 }
42 return line;
43}
44
45function parseFiniteNumber(value: string, lineNumber: number): number {
46 const parsed = Number(value);

Callers 1

parseCubeLutFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected