connection.js 249 B

1234567891011
  1. const sqlite3 = require("sqlite3")
  2. const db = new sqlite3.Database('./data.db', (err) => {
  3. if (err) {
  4. console.log('Could not connect to database', err)
  5. } else {
  6. console.log('Connected to database')
  7. }
  8. });
  9. module.exports = db