1.2.0 • Published 2 years ago

zizo v1.2.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

ZiZo -- Zinthu Zothandiza Utilities

⚠️ THIS IS NOT READY FOR USE YET

This package contains helper functions that I use almost everyday in my NodeJs Projects. So, I decided to create a package. I hope this helps.

Database Helper Functions

Fundamentally, the functions use Knex and Postgres as Database.

  1. Provide a connector and a logger
import { ZizoDataAccessor } from 'zizo';
const connector = knexfile('path to knexfile')

const logger = bunyan.createLogger({
    name: 'NAME_OF_APP'
});

const database = new Zizo(connecto, logger);
  1. Check if record exists
 await database.recordExists("TABLE_NAME", 'COLUMN', 'VALUE' )
1.2.0

2 years ago

1.1.0

2 years ago

1.0.0

2 years ago