@grafana/create-plugin 6.8.0-canary.2356.20813982803.0 → 6.8.0-canary.2356.20814023201.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -14,8 +14,8 @@ function bundleGrafanaUI(context, _options) {
14
14
  additionsDebug("Running bundle-grafana-ui addition...");
15
15
  ensureMinGrafanaVersion(context);
16
16
  updateExternalsArray(context, createBundleGrafanaUIModifier());
17
- updateResolveExtensionsSimple(context);
18
- updateModuleRulesSimple(context);
17
+ updateResolveExtensions(context);
18
+ updateModuleRules(context);
19
19
  return context;
20
20
  }
21
21
  function isGrafanaRegex(element, pattern) {
@@ -78,7 +78,7 @@ function createBundleGrafanaUIModifier() {
78
78
  return removeGrafanaUiAndAddReactInlineSvg(externalsArray);
79
79
  };
80
80
  }
81
- function updateResolveExtensionsSimple(context) {
81
+ function updateResolveExtensions(context) {
82
82
  const configPath = context.doesFileExist(RSPACK_CONFIG_PATH) ? RSPACK_CONFIG_PATH : context.doesFileExist(WEBPACK_CONFIG_PATH) ? WEBPACK_CONFIG_PATH : null;
83
83
  if (!configPath) {
84
84
  return;
@@ -101,7 +101,7 @@ function updateResolveExtensionsSimple(context) {
101
101
  additionsDebug("Added '.mjs' to resolve.extensions");
102
102
  }
103
103
  }
104
- function updateModuleRulesSimple(context) {
104
+ function updateModuleRules(context) {
105
105
  const configPath = context.doesFileExist(RSPACK_CONFIG_PATH) ? RSPACK_CONFIG_PATH : context.doesFileExist(WEBPACK_CONFIG_PATH) ? WEBPACK_CONFIG_PATH : null;
106
106
  if (!configPath) {
107
107
  return;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@grafana/create-plugin",
3
- "version": "6.8.0-canary.2356.20813982803.0",
3
+ "version": "6.8.0-canary.2356.20814023201.0",
4
4
  "repository": {
5
5
  "directory": "packages/create-plugin",
6
6
  "url": "https://github.com/grafana/plugin-tools"
@@ -55,5 +55,5 @@
55
55
  "engines": {
56
56
  "node": ">=20"
57
57
  },
58
- "gitHead": "fedff1c23ee3079d90f0ed2d6984c78fb294b1b9"
58
+ "gitHead": "c56736e56659f6e4b808d59225f1807e32e94062"
59
59
  }
@@ -26,10 +26,10 @@ export default function bundleGrafanaUI(context: Context, _options: BundleGrafan
26
26
  updateExternalsArray(context, createBundleGrafanaUIModifier());
27
27
 
28
28
  // Update bundler resolve configuration to handle ESM imports
29
- updateResolveExtensionsSimple(context);
29
+ updateResolveExtensions(context);
30
30
 
31
31
  // Update module rules directly with simple string manipulation
32
- updateModuleRulesSimple(context);
32
+ updateModuleRules(context);
33
33
 
34
34
  return context;
35
35
  }
@@ -132,10 +132,9 @@ function createBundleGrafanaUIModifier(): ExternalsArrayModifier {
132
132
  }
133
133
 
134
134
  /**
135
- * Updates resolve extensions to add .mjs using simple string manipulation
136
- * This is a simplified approach that may not handle all edge cases, but is much simpler
135
+ * Updates resolve extensions to add .mjs using string manipulation
137
136
  */
138
- function updateResolveExtensionsSimple(context: Context): void {
137
+ function updateResolveExtensions(context: Context): void {
139
138
  const configPath = context.doesFileExist(RSPACK_CONFIG_PATH)
140
139
  ? RSPACK_CONFIG_PATH
141
140
  : context.doesFileExist(WEBPACK_CONFIG_PATH)
@@ -171,10 +170,9 @@ function updateResolveExtensionsSimple(context: Context): void {
171
170
  }
172
171
 
173
172
  /**
174
- * Updates module rules to add .mjs rule using simple string manipulation
175
- * This is a simplified approach that may not handle all edge cases, but is much simpler
173
+ * Updates module rules to add .mjs rule using string manipulation
176
174
  */
177
- function updateModuleRulesSimple(context: Context): void {
175
+ function updateModuleRules(context: Context): void {
178
176
  const configPath = context.doesFileExist(RSPACK_CONFIG_PATH)
179
177
  ? RSPACK_CONFIG_PATH
180
178
  : context.doesFileExist(WEBPACK_CONFIG_PATH)