mysql
mysql copied to clipboard
Ability to pass in types to .query()
At the moment it seems .query() returns type any, but it would be nice if I could pass in a generic to say what type will be returned from it.
mysql.query<{ id: number }[]>('SELECT id from aTable')
// Type: Promise<{ id: number }[]>