@supabase/pg-admin-js

0.0.2 • Public • Published

pg-admin-js

JS SDK for managing your PostgreSQL Database.

Install

$ npm install ...

Usage

var pgAdmin = require('pg-admin-js')
var connection = {
  user: 'postgres',
  password: '123',
  host: 'localhost',
  port: 5432,
  database: 'thedb',
}
pgAdmin.toJSON(connection, 'public')
  .then(({ tables, views, constraints, sequences, counts }) => {
    // handle json object
    console.log('tables', tables)
    console.log('views', views)
    console.log('constraints', constraints)
    console.log('sequences', sequences)
    console.log('counts', counts)
  })
  .catch(function(error) {
    // handle error
  })

License

MIT

Dependencies (3)

Dev Dependencies (2)

Package Sidebar

Install

npm i @supabase/pg-admin-js

Weekly Downloads

0

Version

0.0.2

License

MIT

Unpacked Size

10.3 kB

Total Files

17

Last publish

Collaborators

  • lakshan-supabase
  • etienne_supa
  • ziinc_supabase
  • kamilogorek
  • stdim
  • gregnr
  • soedirgo
  • inian
  • kiwicopple
  • ange1ico
  • awalias
  • phamhieu1998