Package Exports
- dbasefy
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (dbasefy) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
DBasefy
DBasefy is a database encapsulator library. Created in TypeScript serves to encapsulate the implementation complexity from databases, that helps on polymorphism
import { Connection } from 'dbasefy'
const createConnection(): Connention {
// Mock is just a testable class, simply to simulate a connection class
return new MockConnection()
}
async function basicUsageSample(): Promise<void> {
const conn = await createConnection().open()
try {
const cmd = conn.createCommand()
await cmd.execute()
} finally {
await conn.close()
}
}
basicUsageSample()