Socket
Book a DemoInstallSign in
Socket

composition-debugger

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

composition-debugger

Set a breakpoint in a composition

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

Problem

var dasherize = compose(join('-'), toLower, split(' '), replace(/\s{2,}/ig, ' '));

dasherize('The world is a vampire');
// TypeError: Cannot read property 'apply' of undefined

What arguments is toLower called with? What does split(' ') return?

Let's debugger

// index.js
const cdebugger = require('composition-debugger');

var dasherize = compose(join('-'), toLower, cdebugger, split(' '), replace(/\s{2,}/ig, ' '));
// nodejs will pause after `split(' ')`

dasherize('The world is a vampire');
node inspect index.js

Alternatives

  • treis
  • tap
  • do
  • composition-trace

Keywords

fp

FAQs

Package last updated on 13 Jun 2018

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