4、测试 typescript 环境,新文件夹 src 并添加文件 server.ts
console.log("Hello TypeScript");
在 package.json 中加入
"scripts": { "build": "tsc" }
运行
yarn run build
node ./dist/server.js
输出
Hello TypeScript
至此 typescript 环境 配置完成
目录结构如下:

typescript-koa-postgresql 实现一个简单的rest风格服务器 —— typescript 开发环境配置
标签:mon res postgresq 编译环境 alt 简单 rop serve nodejs