This repository has been archived on 2024-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
nodejs-razor/test.js

15 lines
471 B
JavaScript

let parser = require("./init");
let {writeFile} = require("node:fs/promises");
async function main()
{
let node = await parser.processFile("./source/abc.blade.php");
await writeFile("./source/abc.blade.php.js", node.parsedContent, "utf8");
let result = node.execute({
ebilet: 25
});
await writeFile("./source/abc.blade.php.cache", node.cachedData, "utf8");
await writeFile("./target/abc.html", result, "utf8");
};
process.nextTick(main);