Socket
Socket
Sign inDemoInstall

babel-plugin-transform-typescript-metadata

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-plugin-transform-typescript-metadata

Babel plugin to emit decorator metadata like typescript compiler


Version published
Weekly downloads
1.6M
decreased by-0.9%
Maintainers
1
Weekly downloads
 
Created

What is babel-plugin-transform-typescript-metadata?

babel-plugin-transform-typescript-metadata is a Babel plugin that enables the transformation of TypeScript metadata for use with decorators. This is particularly useful for libraries that rely on metadata reflection, such as dependency injection frameworks.

What are babel-plugin-transform-typescript-metadata's main functionalities?

Transform TypeScript Metadata

This feature allows the transformation of TypeScript metadata, making it available for use with decorators. This is particularly useful for dependency injection frameworks that rely on metadata reflection.

/* .babelrc */
{
  "plugins": [
    "babel-plugin-transform-typescript-metadata"
  ]
}

/* Example TypeScript file */
import 'reflect-metadata';

class Example {
  constructor(@Inject('MyService') private myService: MyService) {}
}

// After transformation, metadata about the 'myService' parameter will be available

Other packages similar to babel-plugin-transform-typescript-metadata

Keywords

FAQs

Package last updated on 19 Mar 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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