From 4552a8a2c7561f3b7efff621885514bfd285a2f1 Mon Sep 17 00:00:00 2001 From: Jon Surrell Date: Tue, 10 Sep 2024 11:19:06 +0200 Subject: [PATCH] Use wp-script-module main field This better aligns with "Script Modules" naming in Core. --- packages/interactivity-router/package.json | 2 +- packages/interactivity/package.json | 2 +- tools/webpack/script-modules.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/interactivity-router/package.json b/packages/interactivity-router/package.json index cc38acc155e484..cb920bae7ec2b0 100644 --- a/packages/interactivity-router/package.json +++ b/packages/interactivity-router/package.json @@ -24,7 +24,7 @@ }, "main": "build/index.js", "module": "build-module/index.js", - "wp-module": "build-module/index.js", + "wp-script-module": "build-module/index.js", "react-native": "src/index", "types": "build-types", "dependencies": { diff --git a/packages/interactivity/package.json b/packages/interactivity/package.json index 33576001176b57..9ece9d7e9ac0de 100644 --- a/packages/interactivity/package.json +++ b/packages/interactivity/package.json @@ -24,7 +24,7 @@ }, "main": "build/index.js", "module": "build-module/index.js", - "wp-module": "build-module/index.js", + "wp-script-module": "build-module/index.js", "react-native": "src/index", "types": "build-types", "dependencies": { diff --git a/tools/webpack/script-modules.js b/tools/webpack/script-modules.js index 295eb619fb34af..1d5e2c3e398703 100644 --- a/tools/webpack/script-modules.js +++ b/tools/webpack/script-modules.js @@ -45,7 +45,7 @@ module.exports = { }, resolve: { extensions: [ '.js', '.ts', '.tsx' ], - mainFields: [ 'wp-module' ], + mainFields: [ 'wp-script-module' ], }, module: { rules: [