You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

rollup-plugin-polyfill-node

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rollup-plugin-polyfill-node

rollup-plugin-polyfill-node ===

0.13.0
latest
Source
npmnpm
Version published
Weekly downloads
261K
-15.23%
Maintainers
1
Weekly downloads
 
Created

What is rollup-plugin-polyfill-node?

The rollup-plugin-polyfill-node package is a Rollup plugin that provides polyfills for Node.js core modules, allowing you to use Node.js-specific modules in a browser environment. This is particularly useful for bundling libraries that were originally designed for Node.js but need to run in a browser.

What are rollup-plugin-polyfill-node's main functionalities?

Polyfill Node.js core modules

This feature allows you to polyfill Node.js core modules such as 'fs', 'path', 'crypto', etc., so that they can be used in a browser environment. The code sample demonstrates how to configure Rollup to use the nodePolyfills plugin.

import { nodePolyfills } from 'rollup-plugin-polyfill-node';

export default {
  input: 'src/index.js',
  output: {
    file: 'bundle.js',
    format: 'iife'
  },
  plugins: [
    nodePolyfills()
  ]
};

Other packages similar to rollup-plugin-polyfill-node

Keywords

rollup-plugin

FAQs

Package last updated on 21 Nov 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