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

radix-router

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

radix-router - npm Package Compare versions

Comparing version 0.1.0 to 0.1.1

13

index.js

@@ -11,2 +11,5 @@ 'use strict';

// no-op
function noop() {}
/**

@@ -343,3 +346,3 @@ * Returns all children that match the prefix

'startsWith': function() {
return null;
return [];
}

@@ -356,6 +359,6 @@ };

},
// no ops, (maybe
'delete': function() {},
'insert': function() {},
'startsWith': function() {}
// no ops, (maybe add different functionality later?)
'delete': noop,
'insert': noop,
'startsWith': noop
};

@@ -362,0 +365,0 @@

@@ -13,3 +13,3 @@ {

"name": "radix-router",
"version": "0.1.0",
"version": "0.1.1",
"description": "Radix tree based router",

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

@@ -41,3 +41,3 @@ const {expect} = require('chai');

expect(h2_node.children['oot']).to.not.equal(undefined);
});

@@ -62,3 +62,3 @@

tree.insert('this/:route/has/:cool/stuff/**', 16);
expect(tree.lookup('hello')).to.deep.equal({data: 1});

@@ -74,3 +74,3 @@ expect(tree.lookup('cool')).to.deep.equal({data: 2});

expect(tree.lookup('carbon/test1')).to.deep.equal({
data: 14,
data: 14,
params: {

@@ -111,3 +111,3 @@ 'element': 'test1'

tree.insert('choot', 7);
tree.delete('choot');

@@ -138,3 +138,6 @@ expect(tree.lookup('choot')).to.deep.equal({

expect(setB.hasOwnProperty('chromium')).to.equal(true);
expect(Object.keys(tree.startsWith('batman')).length).to.equal(0);
});
});
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