mirror of
https://github.com/abapGit/abapGit.git
synced 2025-04-30 20:03:20 +08:00

Some checks failed
main-build / build-merged (push) Has been cancelled
main-build / auto-tag (push) Has been cancelled
main-build / coverage (push) Has been cancelled
main-build / auto-tag-artifact (push) Has been cancelled
ajson mirror / pr_ajson_changes (push) Has been cancelled
26 lines
657 B
JavaScript
26 lines
657 B
JavaScript
import express from 'express';
|
|
import {initializeABAP} from "../output/init.mjs";
|
|
import {cl_express_icf_shim} from "../output/cl_express_icf_shim.clas.mjs";
|
|
await initializeABAP();
|
|
|
|
const PORT = 3000;
|
|
|
|
const app = express();
|
|
app.disable('x-powered-by');
|
|
app.set('etag', false);
|
|
app.use(express.raw({type: "*/*"}));
|
|
|
|
// ------------------
|
|
|
|
app.get('/', function (req, res) {
|
|
res.send('path: /');
|
|
});
|
|
|
|
// ------------------
|
|
|
|
app.all(["/sap", "/sap*"], async function (req, res) {
|
|
await cl_express_icf_shim.run({req, res, class: "ZCL_ABAPGIT_WEB_SICF"});
|
|
});
|
|
|
|
app.listen(PORT);
|
|
console.log("Listening on port http://localhost:" + PORT + "/sap/zabapgit/"); |