Skip to content

Instantly share code, notes, and snippets.

@agustinfece
Last active Jun 16, 2021
Embed
What would you like to do?
user.js
import { Sequelize } from 'sequelize';
import sequelize from '../utils/database.js';
const User = sequelize.define('users', {
id: {
type: Sequelize.INTEGER,
autoIncrement: true,
allowNull: false,
primaryKey: true,
},
email: {
type: Sequelize.STRING,
allowNull: false,
},
name: {
type: Sequelize.STRING,
},
password: {
type: Sequelize.STRING,
allowNull: false,
},
});
export default User;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment