Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

find-my-way

Package Overview
Dependencies
Maintainers
2
Versions
112
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

find-my-way - npm Package Compare versions

Comparing version 2.1.0 to 2.1.1

2

node.js

@@ -206,3 +206,3 @@ 'use strict'

}
paramName += ' ' + prefix + ':' + param + ` (${method})`
paramName += prefix + ' :' + param + ` (${method})`
paramName += (index === methods.length - 1 ? '' : '\n')

@@ -209,0 +209,0 @@ } else {

{
"name": "find-my-way",
"version": "2.1.0",
"version": "2.1.1",
"description": "Crazy fast http radix based router",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -93,1 +93,25 @@ 'use strict'

})
test('pretty print - parametric routes with same parent and followed by a static route which has the same prefix with the former routes', t => {
t.plan(2)
const findMyWay = FindMyWay()
findMyWay.on('GET', '/test', () => {})
findMyWay.on('GET', '/test/hello/:id', () => {})
findMyWay.on('POST', '/test/hello/:id', () => {})
findMyWay.on('GET', '/test/helloworld', () => {})
const tree = findMyWay.prettyPrint()
const expected = `└── /
└── test (GET)
└── /hello
├── /
│ └── :id (GET)
│ :id (POST)
└── world (GET)
`
t.is(typeof tree, 'string')
t.equal(tree, expected)
})
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