Giter VIP home page Giter VIP logo

sequelize-docs-zh-cn's Introduction

Sequelize Docs 中文版

npm version Travis Build Status Appveyor Build Status npm downloads codecov Last commit Merged PRs GitHub stars Slack Status node License semantic-release

此项目同步自 sequelize / sequelize 项目中的 docs. 除特殊情况, 将保持每月一次的同步频率.

更新日志请参阅: CHANGELOG

Sequelize 是一个基于 promise 的 Node.js ORM, 目前支持 Postgres, MySQL, MariaDB, SQLite 以及 Microsoft SQL Server. 它具有强大的事务支持, 关联关系, 预读和延迟加载,读取复制等功能.

Sequelize 遵从 语义版本控制. 支持 Node v10 及更高版本以便使用 ES6 功能.

你目前正在查看 Sequelize 的教程和指南.你可能还对API 参考 (英文)感兴趣.

数据库引擎支持

v6

引擎 支持的最低版本
Postgre 9.5
MySQL 5.7
MariaDB 10.1
Microsoft SQL 12.0.2000
SQLite 3.0

版本

v6 中文文档(现行版本)

v5 中文文档(计划停止)

v4 中文文档(停止更新)

文档(v6)

核心概念

高级关联概念

其它主题

简单示例

const { Sequelize, Model, DataTypes } = require('sequelize');
const sequelize = new Sequelize('sqlite::memory:');

class User extends Model {}
User.init({
  username: DataTypes.STRING,
  birthday: DataTypes.DATE
}, { sequelize, modelName: 'user' });

(async () => {
  await sequelize.sync();
  const jane = await User.create({
    username: 'janedoe',
    birthday: new Date(1980, 6, 20)
  });
  console.log(jane.toJSON());
})();

请通过 Getting started - 入门 来学习更多相关内容. 如果你想要学习 Sequelize API 请通过 API 参考 (英文).

赞赏支持

赞赏支持

sequelize-docs-zh-cn's People

Contributors

carlhey avatar cocacolf avatar demopark avatar kennytian avatar simonguo avatar wujjpp avatar xiaohp avatar xiaoyao96 avatar xlfsummer avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.