Open dyst5422 opened 7 years ago
You can just use the @types/mongodb
definition files. For example:
import tingodb from 'tingodb';
import { Db as MongoDb } from 'mongodb';
const Db = tingodb().Db;
const db = <MongoDb> new Db('./database.tingodb', {});
Yeah, you could do that, but since tingo hasn't been fully updated yet to use the new apis it'd be kinda nice to have files which reflected what actually is there...
Should add a Typescript definitions file to DefinitelyTyped. Should be as simple as copying the official MongoDB definition and pruning it.