blog开发踩坑记

Node.js 手册查询-3-Mongoose 方法    https://cnodejs.org/topic/548e54d157fd3ae46b233502 

ele ui验证问题

 koa写入cookie

        // 写入cookie                
        ctx.cookies.set("userId", result._id, {
          domain: 'localhost',
          path: '/', //cookie写入的路径
          maxAge: 1000 * 60 * 60 * 1,
          expires: new Date('2018-10-06'),
          httpOnly: false,
          overwrite: false
        })
posted @ 2018-06-09 22:34  看起来没睡醒  阅读(137)  评论(0编辑  收藏  举报