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

rsdi

Package Overview
Dependencies
Maintainers
1
Versions
41
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rsdi - npm Package Compare versions

Comparing version 3.0.0-alpha.1 to 3.0.0-alpha.2

.nvmrc

10

package.json
{
"name": "rsdi",
"version": "3.0.0-alpha.1",
"version": "3.0.0-alpha.2",
"description": "TypeScript dependency injection container. Strong types without decorators.",

@@ -14,5 +14,2 @@ "keywords": [

],
"files": [
"dist/**"
],
"lint-staged": {

@@ -24,4 +21,5 @@ "src/**/*.ts": [

},
"main": "dist/index.js",
"types": "dist/index.d.ts",
"type": "module",
"main": "./dist/index.js",
"types": "./dist/index.d.ts",
"homepage": "https://github.com/radzserg/rsdi",

@@ -28,0 +26,0 @@ "author": "Sergey Radzishevskii <radzserg@gmail.com>",

@@ -82,5 +82,5 @@ # RSDI - Dependency Injection Container

.add("bar", () => new Bar())
.add("foo", (get) => new Foo(get("a"), get("bar")));
.add("foo", ({ a, bar}) => new Foo(a, bar));
const foo = container.get("foo");
const { foo } = container; // or container.get("foo");
```

@@ -144,8 +144,8 @@

.add("dbConnection", buildDbConnection())
.add("userRepository", (get) =>
MyDbProviderUserRepository(get("dbConnection")),
.add("userRepository", ({ dbConnection }) =>
MyDbProviderUserRepository(dbConnection),
)
.add("userRegistrator", (get) => new UserRegistrator(get("userRepository")))
.add("userController", (get) =>
UserController(get("userRepository"), get("userRegistrator")),
.add("userRegistrator", ({ userRepository }) => new UserRegistrator(userRepository))
.add("userController", ({ userRepository, userRegistrator}) =>
UserController(userRepository, userRegistrator),
);

@@ -197,2 +197,6 @@ }

![strict type](https://github.com/radzserg/rsdi3/raw/main/docs/RSDI_types.png "RSDI types")
![strict type](https://github.com/radzserg/rsdi3/raw/main/docs/RSDI_types.png "RSDI types")
## Best practices
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