【文件属性】:
文件名称:stream-orderby:nodejs 上流 json 对象的 orderby
文件大小:5KB
文件格式:ZIP
更新时间:2021-05-30 00:25:34
JavaScript
流顺序
nodejs 上流 json 对象的 orderby
##例子:
generator ( 5 ) . pipe ( orderBy ( [
{
keys : 'grade.name,value' ,
reverse : true
} , {
getValue : function ( doc ) {
return doc . age ;
} ,
reverse : false
} , 'name'
] ) ) . on ( 'data' , function ( doc ) {
return console . log ( doc ) ;
} ) . once ( 'end' , function ( ) {
console . log ( "order by end." ) ;
} ) ;
如果您读取
【文件预览】:
stream-orderby-master
----test()
--------test.coffee(720B)
--------test.js(960B)
--------test.js.map(1KB)
----README.md(517B)
----.gitignore(2KB)
----orderby.js(3KB)
----package.json(669B)