上一页 1 2 3 4 5 6 7 8 9 ··· 16 下一页
摘要: // 获取get值 router.get('/b', async(ctx, next) => { ctx.state = { title: 'Koa2', name: '小明-list' } let url = ctx.url // 从上下文中直接获取 let ctx_query = ctx.query ctx.... 阅读全文
posted @ 2017-05-14 22:45 次序 阅读(12682) 评论(0) 推荐(0) 编辑
摘要: const http = require('http'); const querystring = require('querystring'); const postData = querystring.stringify({ 'msg': 'Hello World! ----- 哈利路亚' }); const options = { hostname: '192.168.1.6'... 阅读全文
posted @ 2017-05-11 18:01 次序 阅读(433) 评论(0) 推荐(0) 编辑
摘要: const http = require('http'); http.get('http://192.168.1.6:8080/getDemo?msg=12', (res) => { const { statusCode } = res; const contentType = res.headers['content-type']; let error; if (statu... 阅读全文
posted @ 2017-05-11 18:00 次序 阅读(477) 评论(0) 推荐(0) 编辑
摘要: npm install –g n n latest 阅读全文
posted @ 2017-05-10 22:49 次序 阅读(634) 评论(0) 推荐(0) 编辑
摘要: 如何从EPEL库安装Node.js 另一个有效且简单的方法来安装Node.js就是从官方库。这同样确保您可以访问到EPEL库,你可以通过运行以下命令。 sudo yum install epel-release 现在可以使用yum命令安装Node.js了。 sudo yum install node 阅读全文
posted @ 2017-05-10 22:37 次序 阅读(2723) 评论(0) 推荐(0) 编辑
摘要: // 从服务器获取数据 request('http://192.168.1.7:8080/getDemo', function(error, response, body) { console.log('error:', error); console.log('statusCode:', response && response.statusCode); console.log(... 阅读全文
posted @ 2017-05-10 16:33 次序 阅读(1253) 评论(0) 推荐(0) 编辑
摘要: const Koa = require('koa'); const Router = require('koa-router'); const app = new Koa(); const router = new Router(); const views = require('koa-views'); const json = require('koa-json'); const onerr... 阅读全文
posted @ 2017-05-09 20:20 次序 阅读(3399) 评论(0) 推荐(0) 编辑
摘要: Npm i -g yarn 第一步,先查看本机node.js版本: 阅读全文
posted @ 2017-05-08 17:34 次序 阅读(11277) 评论(0) 推荐(1) 编辑
摘要: 播放 阅读全文
posted @ 2017-05-03 17:17 次序 阅读(1748) 评论(0) 推荐(0) 编辑
摘要: brew install ffmpeg --with-libvpx or brew reinstall ffmpeg --with-libvpx 阅读全文
posted @ 2017-04-30 20:50 次序 阅读(639) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 ··· 16 下一页