Related to #29.
This is what works now:
const { EleventyServerlessBundlerPlugin } = require("@11ty/eleventy");
module.exports = function(eleventyConfig) {
eleventyConfig.setServerOptions({
middleware: [function overrideMiddleware(req, res, next) {
// This works now
res.writeHead(200, {"content-type": "text/html"}); // content-type header required for live-reload
res.write("Before Text");
res.end();
next();
}],
});
});
However, I’d like to see folks able to consume res.statusCode (404 when no file is present) and res.body with the static content to do request-time content transforms
Related to #29.
This is what works now:
However, I’d like to see folks able to consume
res.statusCode(404 when no file is present) andres.bodywith the static content to do request-time content transforms