sjinks / knex-mariadb

MariaDB Client for Knex.js
https://wildwolf.name/mariadb-driver-for-knex/
MIT License
7 stars 2 forks source link

TypeScript type definition file #47

Open jcwatson11 opened 2 years ago

jcwatson11 commented 2 years ago

Hello there! I'm new to typescript and not quite sure how to write a typescript definition file yet or I would contribute it myself. But is there any chance that you could add one for this very simple drop-in? Seems like it should be pretty simple.

TonyGravagno commented 1 week ago

Not a full solution but to get this utility to work with Knex in a TypeScript project, just create a file named knex.d.ts in the same folder as your .ts that uses the library. In that file, add one line:

declare module 'knex-mariadb';

HTH