Skip to content

Instantly share code, notes, and snippets.

@chuck0523

chuck0523/schema_after.js

Last active Feb 14, 2016
Embed
What would you like to do?
module.exports = (function() {
"use strict";
const Nodal = require('nodal');
class CreateWord extends Nodal.Migration {
constructor(db) {
super(db);
this.id = 2016021122463566;
}
up() {
return [
this.createTable("words", [{"name": "nane", "type": "string", "properties": {"nullable":false}},
{"name": "meaning", "type": "string", "properties": {"nullable":false}}])
];
}
down() {
return [
this.dropTable("words")
];
}
}
return CreateWord;
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment