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

@surma/rollup-plugin-off-main-thread

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@surma/rollup-plugin-off-main-thread - npm Package Compare versions

Comparing version 1.4.1 to 1.4.2

12

index.js

@@ -37,3 +37,5 @@ /**

// The scheme used when importing workers as a URL.
urlLoaderScheme: "omt"
urlLoaderScheme: "omt",
// Silence the warning about ESM being badly supported in workers.
silenceESMWorkerWarning: false,
};

@@ -58,3 +60,3 @@

outputOptions({ format }) {
if (format === "esm" || format === "es") {
if ((format === "esm" || format === "es") && !opts.silenceESMWorkerWarning) {
this.warn(

@@ -76,6 +78,6 @@ 'Very few browsers support ES modules in Workers. If you want to your code to run in all browsers, set `output.format = "amd";`'

const path = id.slice(urlLoaderPrefix.length);
const newId = (await this.resolve(path, importer)).id;
const resolved = await this.resolve(path, importer);
if (!resolved) throw Error(`Cannot find module '${path}' from '${importer}'`);
const newId = resolved.id;
if (!newId) throw Error(`Cannot find module '${path}'`);
return urlLoaderPrefix + newId;

@@ -82,0 +84,0 @@ },

{
"name": "@surma/rollup-plugin-off-main-thread",
"version": "1.4.1",
"version": "1.4.2",
"description": "Use Rollup with workers and ES6 modules today.",

@@ -5,0 +5,0 @@ "main": "index.js",

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