Socket
Socket
Sign inDemoInstall

pull-traverse

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pull-traverse

[![travis](https://travis-ci.org/dominictarr/pull-traverse.png?branch=master)](https://travis-ci.org/dominictarr/pull-traverse)


Version published
Maintainers
1
Created
Source

pull-traverse

travis

depthFirst, widthFirst, leafFirst (start, createStream)

Traverse a tree structure. start is a value that represents a node. createStream is a function that returns a pull-stream of the children of a node. start must be the same type output by createStream.

var pull = require('pull-stream')
var pt   = require('pull-traverse')

pull(
  pt.widthFirst(objects, function (object) {
    if(object && 'object' === typeof object)
      return pull.values(object)
    return pull.empty()
  }),
  pull.log()
)

License

MIT

FAQs

Package last updated on 14 Nov 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc