MCPcopy
hub / github.com/vitejs/vite / error

Function error

packages/vite/src/node/server/hmr.ts:1124–1131  ·  view source on GitHub ↗
(pos: number)

Source from the content-addressed store, hash-verified

1122}
1123
1124function error(pos: number) {
1125 const err = new Error(
1126 `import.meta.hot.accept() can only accept string literals or an ` +
1127 `Array of string literals.`,
1128 ) as RollupError
1129 err.pos = pos
1130 throw err
1131}
1132
1133// vitejs/vite#610 when hot-reloading Vue files, we read immediately on file
1134// change event and sometimes this can be too early and get an empty buffer.

Callers 1

lexAcceptedHmrDepsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected