@leftium/gg 0.0.18 → 0.0.19

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.
Files changed (2) hide show
  1. package/dist/gg.js +10 -0
  2. package/package.json +1 -1
package/dist/gg.js CHANGED
@@ -82,6 +82,13 @@ const srcRootRegex = new RegExp(ggConfig.srcRootPattern, 'i');
82
82
  // - Cache and reuse the same log function for a given callpoint.
83
83
  const namespaceToLogFunction = new Map();
84
84
  let maxCallpointLength = 0;
85
+ /**
86
+ * Reset the namespace width tracking.
87
+ * Useful after configuration checks that may have long callpoint paths.
88
+ */
89
+ function resetNamespaceWidth() {
90
+ maxCallpointLength = 0;
91
+ }
85
92
  function openInEditorUrl(fileName) {
86
93
  return ggConfig.openInEditorUrlTemplate.replace('$FILENAME', encodeURIComponent(fileName).replaceAll('%2F', '/'));
87
94
  }
@@ -179,4 +186,7 @@ if (ggConfig.showHints && !isCloudflareWorker()) {
179
186
  message(`${checkbox(ggLogTest.enabled)} DEBUG env variable: ${process?.env?.DEBUG}${hint}`);
180
187
  }
181
188
  console.log(ggMessage);
189
+ // Reset namespace width after configuration check
190
+ // This prevents the long callpoint from the config check from affecting subsequent logs
191
+ resetNamespaceWidth();
182
192
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@leftium/gg",
3
- "version": "0.0.18",
3
+ "version": "0.0.19",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/Leftium/gg.git"