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

@types/source-map-support

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/source-map-support

TypeScript definitions for source-map-support

  • 0.5.7
  • ts4.3
  • ts4.4
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
409K
decreased by-16.62%
Maintainers
1
Weekly downloads
 
Created

What is @types/source-map-support?

@types/source-map-support provides TypeScript type definitions for the source-map-support package, which is used to enhance the debugging experience by providing better stack traces with source maps.

What are @types/source-map-support's main functionalities?

Install Source Map Support

This feature allows you to install source map support in your Node.js application, enabling better stack traces that map to the original source code.

const sourceMapSupport = require('source-map-support');
sourceMapSupport.install();

Uninstall Source Map Support

This feature allows you to uninstall source map support, reverting to the default stack trace behavior.

const sourceMapSupport = require('source-map-support');
sourceMapSupport.uninstall();

Customizing Source Map Retrieval

This feature allows you to customize how source maps are retrieved, providing a function that returns the source map for a given source file.

const sourceMapSupport = require('source-map-support');
sourceMapSupport.install({
  retrieveSourceMap: function(source) {
    if (source === 'compiled.js') {
      return {
        url: 'compiled.js',
        map: fs.readFileSync('compiled.js.map', 'utf8')
      };
    }
    return null;
  }
});

Other packages similar to @types/source-map-support

FAQs

Package last updated on 22 Aug 2023

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