Commit e5726bfa authored by nagayama15's avatar nagayama15

Implement the simplest express server

parent b30a9040
...@@ -2,3 +2,4 @@ ...@@ -2,3 +2,4 @@
/.vscode/ /.vscode/
node_modules/ node_modules/
dist/
...@@ -2,3 +2,4 @@ ...@@ -2,3 +2,4 @@
/.vscode/ /.vscode/
node_modules/ node_modules/
dist/
...@@ -3,7 +3,11 @@ ...@@ -3,7 +3,11 @@
"version": "1.0.0", "version": "1.0.0",
"description": "A WebAssembly Watermarking Server", "description": "A WebAssembly Watermarking Server",
"main": "index.js", "main": "index.js",
"scripts": {}, "scripts": {
"start": "node dist/index.js",
"dev": "ts-node src/index.ts",
"build": "tsc"
},
"repository": { "repository": {
"type": "git", "type": "git",
"url": "git@github.com/NagayamaRyoga/wasm-watermark.git" "url": "git@github.com/NagayamaRyoga/wasm-watermark.git"
......
import * as express from "express";
const port = 3000;
const app = express();
const server = app.listen(port, () => {
console.log(`server listening at port ${port}`);
});
{
"compilerOptions": {
"module": "commonjs",
"noImplicitAny": true,
"removeComments": true,
"preserveConstEnums": true,
"outDir": "dist",
"sourceMap": true
},
"include": ["src/**/*"],
"exclude": ["node_modules"]
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment