MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / isStoreFile

Function isStoreFile

src/resolution/callback-synthesizer.ts:4168–4182  ·  view source on GitHub ↗
(file: string)

Source from the content-addressed store, hash-verified

4166 let scannedFiles = 0;
4167 const storeFileCache = new Map<string, boolean>();
4168 const isStoreFile = (file: string): boolean => {
4169 let v = storeFileCache.get(file);
4170 if (v === undefined) {
4171 const c = ctx.readFile(file);
4172 const seen = new Set<string>();
4173 if (c) {
4174 VUEX_STORE_SIGNAL.lastIndex = 0;
4175 let sm: RegExpExecArray | null;
4176 while ((sm = VUEX_STORE_SIGNAL.exec(c))) { seen.add(sm[0]); if (seen.size >= 2) break; }
4177 }
4178 v = seen.size >= 2;
4179 storeFileCache.set(file, v);
4180 }
4181 return v;
4182 };
4183
4184 const resolve = (key: string, dispatchFile: string): Node | null => {
4185 const segs = key.split('/');

Callers 1

resolveFunction · 0.70

Calls 5

readFileMethod · 0.80
getMethod · 0.65
execMethod · 0.65
addMethod · 0.45
setMethod · 0.45

Tested by

no test coverage detected