Express+mongooseで RDBのようなAUTO INCREMENTフィールドを実現する mongoose-sequence パッケージをインストール $ npm install --save mongoose-sequence app.js var mongoose = require('mongoose'); const option = { useMongoClient: true, }; mongoose.Promise = global.Promise; mongoose.connect(`mongodb://localhost/nexpress`, option); // スキーマ定義 var Schema = mongoose.Schema; const AutoIncrement = require('mongoose-sequence')(mongoose);
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く