New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@rspack/plugin-react-refresh

Package Overview
Dependencies
Maintainers
1
Versions
560
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rspack/plugin-react-refresh - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

dist/sockets/WHMEventSource.d.ts

24

dist/index.js

@@ -10,2 +10,14 @@ "use strict";

const getSocketIntegration_1 = require("./utils/getSocketIntegration");
const getIntegrationEntry_1 = require("./utils/getIntegrationEntry");
function addEntry(entry, compiler) {
new compiler.webpack.EntryPlugin(compiler.context, entry, {
name: undefined,
}).apply(compiler);
}
function addSocketEntry(sockIntegration, compiler) {
const integrationEntry = (0, getIntegrationEntry_1.getIntegrationEntry)(sockIntegration);
if (integrationEntry) {
addEntry(integrationEntry, compiler);
}
}
class ReactRefreshRspackPlugin {

@@ -31,10 +43,10 @@ constructor(options = {}) {

for (const entry of addEntries.prependEntries) {
new compiler.webpack.EntryPlugin(compiler.context, entry, {
name: undefined,
}).apply(compiler);
addEntry(entry, compiler);
}
if (this.options.overlay !== false &&
this.options.overlay.sockIntegration) {
addSocketEntry(this.options.overlay.sockIntegration, compiler);
}
for (const entry of addEntries.overlayEntries) {
new compiler.webpack.EntryPlugin(compiler.context, entry, {
name: undefined,
}).apply(compiler);
addEntry(entry, compiler);
}

@@ -41,0 +53,0 @@ new compiler.webpack.ProvidePlugin({

@@ -6,3 +6,3 @@ import type { RuleSetCondition } from '@rspack/core';

module: string;
sockIntegration: IntegrationType;
sockIntegration: IntegrationType | false;
sockHost?: string;

@@ -9,0 +9,0 @@ sockPath?: string;

@@ -1,2 +0,2 @@

export type IntegrationType = 'wds';
export type IntegrationType = 'wds' | 'whm' | (string & {});
export declare function getSocketIntegration(integrationType: IntegrationType): string;

@@ -11,2 +11,6 @@ "use strict";

}
case 'whm': {
resolvedSocketIntegration = require.resolve('../sockets/WHMEventSource');
break;
}
default: {

@@ -13,0 +17,0 @@ resolvedSocketIntegration = require.resolve(integrationType);

{
"name": "@rspack/plugin-react-refresh",
"version": "1.0.1",
"version": "1.0.2",
"repository": "https://github.com/rspack-contrib/rspack-plugin-react-refresh",

@@ -33,5 +33,4 @@ "license": "MIT",

"@rspack/core": "1.1.4",
"@types/jest": "29.5.14",
"@types/node": "^22.10.1",
"@types/jest": "29.5.14",
"react-refresh": "^0.14.2",
"cross-env": "^7.0.3",

@@ -44,5 +43,7 @@ "execa": "9.5.1",

"nano-staged": "^0.8.0",
"react-refresh": "^0.14.2",
"semver": "7.6.3",
"simple-git-hooks": "^2.11.1",
"ts-jest": "29.2.5",
"ts-node": "^10.9.2",
"typescript": "5.7.2"

@@ -52,9 +53,11 @@ },

"error-stack-parser": "^2.1.4",
"html-entities": "^2.5.2"
"html-entities": "^2.5.2",
"@continuous-auth/client": "2.3.2"
},
"peerDependencies": {
"react-refresh": ">=0.10.0 <1.0.0"
"react-refresh": ">=0.10.0 <1.0.0",
"webpack-hot-middleware": "2.x"
},
"peerDependenciesMeta": {
"react-refresh": {
"webpack-hot-middleware": {
"optional": true

@@ -61,0 +64,0 @@ }

@@ -149,2 +149,4 @@ <picture>

Checkout [OverlayOptions](https://github.com/rspack-contrib/rspack-plugin-react-refresh/blob/main/src/options.ts#L4) type signature for more details.
- Enable the error overlay:

@@ -151,0 +153,0 @@

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