IOweb/node_modules/astro/dist/runtime/server/render/instruction.js
2026-07-03 15:07:38 -05:00

17 lines
553 B
JavaScript

const RenderInstructionSymbol = /* @__PURE__ */ Symbol.for("astro:render");
function createRenderInstruction(instruction) {
return Object.defineProperty(instruction, RenderInstructionSymbol, {
value: true
});
}
function isRenderInstruction(chunk) {
return chunk && typeof chunk === "object" && chunk[RenderInstructionSymbol];
}
function isScriptInstruction(chunk) {
return chunk && typeof chunk === "object" && "type" in chunk && chunk.type === "script";
}
export {
createRenderInstruction,
isRenderInstruction,
isScriptInstruction
};