Skip to content

Commit 4a9d24d

Browse files
committed
chore(release): bump version to 3.2.8
1 parent 8f342d8 commit 4a9d24d

File tree

3 files changed

+16
-5
lines changed

3 files changed

+16
-5
lines changed

CHANGELOG.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,14 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8-
## [Unreleased]
8+
## [3.2.8](https://github.com/SocketDev/socket-lib/releases/tag/v3.2.8) - 2025-11-05
9+
10+
### Fixed
11+
12+
- **build**: Fix CommonJS export script edge cases
13+
- Fixed stray semicolons after comment placeholders in transformed modules
14+
- Fixed incorrect transformation of `module.exports.default` to `module.module.exports`
15+
- Ensures external dependencies and default exports work correctly
916

1017
## [3.2.7](https://github.com/SocketDev/socket-lib/releases/tag/v3.2.7) - 2025-11-05
1118

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@socketsecurity/lib",
3-
"version": "3.2.7",
3+
"version": "3.2.8",
44
"license": "MIT",
55
"description": "Core utilities and infrastructure for Socket.dev security tools",
66
"keywords": [

scripts/fix-commonjs-exports.mjs

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -266,11 +266,15 @@ async function processDirectory(dir, verbose = false) {
266266
// Check if this is preceded by 'module.' or 'moduleN.' (from esbuild CommonJS wrapper)
267267
const beforeModule = pos - 'module.'.length
268268
const beforeModule2 = pos - 'module2.'.length
269-
const isModule = beforeModule >= 0 && content.slice(beforeModule, pos) === 'module.'
270-
const isModule2 = beforeModule2 >= 0 && content.slice(beforeModule2, pos) === 'module2.'
269+
const isModule =
270+
beforeModule >= 0 &&
271+
content.slice(beforeModule, pos) === 'module.'
272+
const isModule2 =
273+
beforeModule2 >= 0 &&
274+
content.slice(beforeModule2, pos) === 'module2.'
271275
// Also check for generic moduleN. pattern
272276
const beforeText = content.slice(Math.max(0, pos - 10), pos)
273-
const hasModuleNPrefix = /module\d*\.$/ .test(beforeText)
277+
const hasModuleNPrefix = /module\d*\.$/.test(beforeText)
274278

275279
if (isModule || isModule2 || hasModuleNPrefix) {
276280
// Skip moduleN.exports.default (it's already from esbuild wrapper)

0 commit comments

Comments
 (0)