When attempting to serve a load.css
file alongside index.html
, I am encountering a 404 error. I experimented with manually setting the res.body == load.css
data, but this caused the request to remain stuck on loading.
What could be causing this issue?
void foo() {
crow::SimpleApp app;
crow::mustache::set_global_base("/home/cereza/testing/src/frontend/src/");
CROW_ROUTE(app, "/") ([] () {
auto page = crow::mustache::load("html/index.html");
return page.render();
});
CROW_ROUTE(app, "/style/load.css") ([] () {
crow::response res;
res.set_static_file_info("style/load.css");
return res;
});
}
I have already attempted adjusting paths and verifying if files are being correctly retrieved.