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

didi

Package Overview
Dependencies
Maintainers
1
Versions
39
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

didi - npm Package Compare versions

Comparing version 0.0.4 to 0.1.0

0

lib/annotation.js

@@ -0,0 +0,0 @@

@@ -0,0 +0,0 @@ module.exports = {

21

lib/injector.js

@@ -9,5 +9,10 @@ var Module = require('./module');

parent = parent || {
get: function(name) {
get: function(name, strict) {
currentlyResolving.push(name);
throw error('No provider for "' + name + '"!');
if (strict === false) {
return null;
} else {
throw error('No provider for "' + name + '"!');
}
}

@@ -28,3 +33,11 @@ };

var get = function(name) {
/**
* Return a named service.
*
* @param {String} name
* @param {Boolean} [strict=true] if false, resolve missing services to null
*
* @return {Object}
*/
var get = function(name, strict) {
if (!providers[name] && name.indexOf('.') !== -1) {

@@ -58,3 +71,3 @@ var parts = name.split('.');

return parent.get(name);
return parent.get(name, strict);
};

@@ -61,0 +74,0 @@

@@ -0,0 +0,0 @@ var Module = function() {

2

package.json
{
"name": "didi",
"version": "0.0.4",
"version": "0.1.0",
"description": "Dependency Injection for JavaScript",

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

@@ -0,0 +0,0 @@ # Dependency Injection for JavaScript

Sorry, the diff of this file is not supported yet

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