0.7.33 • Published 3 years ago
@luics/typeorm-server v0.7.33
Typeorm-Server
Inspired by json-server.
Install
global install
npm i -g ts-node @luics/typeorm-serverlocal install
npm i -D ts-node @luics/typeorm-serverCli use
global
typeorm-server --config "typeorm-server.json"npm script
npx typeorm-server --config "typeorm-server.json"typeorm-server.json sample:
{
"typeorm": {
"host": "localhost",
"port": 3306,
"username": "test",
"password": "test",
"database": "test",
"synchronize": false,
"logging": false,
"entities": ["path/to/entity/*.entity.{ts,js}"]
},
"schema": "path/to/entity/schema.json"
}full doc see TypeormServerConfig
Programmatic use
const app = express();
app.use(express.text({ type: '*/*' }));
app.use(cors({ origin: true, credentials: true }));
app.get('/', (_req, res) => res.json({}));
await useTypeormServerRoutersAsync(app, config, prefix);0.7.33
3 years ago
0.7.19
4 years ago
0.7.16
4 years ago
0.7.22
4 years ago
0.7.21
4 years ago
0.7.24
4 years ago
0.7.23
4 years ago
0.7.20
4 years ago
0.7.29
4 years ago
0.7.26
4 years ago
0.7.25
4 years ago
0.7.28
4 years ago
0.7.27
4 years ago
0.7.15
4 years ago
0.7.13
4 years ago
0.7.12
4 years ago
0.7.11
4 years ago
0.7.10
4 years ago
0.7.9
4 years ago
0.7.8
4 years ago
0.7.7
4 years ago
0.7.6
4 years ago
0.7.5
4 years ago
0.7.4
4 years ago
0.7.3
4 years ago
0.7.2
4 years ago
0.7.1
4 years ago
0.7.0
4 years ago