Inversify Props screenshot

Inversify Props

Author Avatar Theme by Ckgrafico
Updated: 31 Dec 2022
85 Stars

Wrapper of Inversify to inject your dependencies in the components, made with TypeScript and compatible with Vue, React and other component libraries.

Categories

Overview:

The Inversify Props package is a wrapper for the Inversify dependency injection library. It simplifies the process of injecting dependencies with property decorators in components. The package is written in TypeScript and is compatible with Vue, React, and other component libraries. It also includes an experimental package for using Hooks. The goal of this package is to provide a simple wrapper that makes dependency injection easier for developers.

Features:

  • Simplifies dependency injection in components using property decorators
  • Compatible with Vue, React, and other component libraries
  • Experimental package for using Hooks
  • Provides a container to make dependency injection easier, but developers can create their own container
  • Supports minification and obfuscation of the build output

Installation:

  1. Install the inversify-props npm package.
  2. If you use a minifier or obfuscator, configure it to preserve class and function names in the build output.
  3. Ensure that your TypeScript configuration file (tsconfig.json) includes the experimentalDecorators, emitDecoratorMetadata, types, and lib compilation options.
  4. Register your dependencies in the container.

Summary:

The Inversify Props package is a wrapper for the Inversify dependency injection library. It simplifies the process of injecting dependencies in components using property decorators. It is compatible with Vue, React, and other component libraries. The package provides a container to make dependency injection easier, but developers can also create their own container. The package also includes an experimental package for using Hooks. Overall, the Inversify Props package aims to simplify the process of dependency injection and make the developer’s experience smoother.