{"version":3,"file":"dev.mjs","names":[],"sources":["../../src/reporters/dev.ts"],"sourcesContent":["import type { DiagnosticReporter } from '../diagnostic'\n\n/**\n * Creates a reporter for browser code under Vite dev: it forwards each\n * diagnostic over `import.meta.hot.send('nostics:report', ...)` so the\n * dev-server collector can file it. Outside Vite (`import.meta.hot` absent) it\n * warns once and does nothing.\n */\n/* @__NO_SIDE_EFFECTS__ */\nexport function createDevReporter(): DiagnosticReporter {\n  return (diagnostic) => {\n    if (import.meta.hot && typeof import.meta.hot.send === 'function') {\n      import.meta.hot.send('nostics:report', diagnostic.toJSON())\n    }\n    else {\n      console.warn(\n        '[nostics]: import.meta.hot.send() is not available. This must be running on Vite.',\n      )\n    }\n  }\n}\n"],"mappings":";;;;;;;;AASA,SAAgB,oBAAwC;CACtD,QAAQ,eAAe;EACrB,IAAI,OAAO,KAAK,OAAO,OAAO,OAAO,KAAK,IAAI,SAAS,YACrD,OAAO,KAAK,IAAI,KAAK,kBAAkB,WAAW,OAAO,CAAC;OAG1D,QAAQ,KACN,mFACF;CAEJ;AACF"}