Permalink
Fetching contributors…
Cannot retrieve contributors at this time
18 lines (13 sloc) 328 Bytes

Schema Usage

You can get an instance of the Schema class via your Database instance:

var schema = db.schema();

Now you have access to methods like, creating or dropping tables for example:

db.schema()
  .dropTable('posts')
  .then(function () {
    console.log('Successfully dropped the table');
  });