MCPcopy Index your code
hub / github.com/markmap/markmap / constructor

Method constructor

packages/markmap-cli/src/util/dev-server.ts:107–114  ·  view source on GitHub ↗
(
    key: string,
    readonly filePath: string,
    watch: (callback: () => void) => () => void,
  )

Source from the content-addressed store, hash-verified

105 implements IContentProvider
106{
107 constructor(
108 key: string,
109 readonly filePath: string,
110 watch: (callback: () => void) => () => void,
111 ) {
112 super(key);
113 this.disposeList.push(watch(() => this.update()));
114 }
115
116 async update() {
117 const content = await readFile(this.filePath, 'utf8');

Callers

nothing calls this directly

Calls 1

updateMethod · 0.95

Tested by

no test coverage detected