Skip to content

Releases: exuanbo/module-from-string

v3.3.0

16 Sep 09:41
v3.3.0
ad67f21
Compare
Choose a tag to compare

Features

  • Add option filename for better exception stack trace.

v3.2.1

02 Aug 19:46
v3.2.1
d91a013
Compare
Choose a tag to compare

Bug Fixes

  • File URL was incorrectly converted to path in import() expression.
  • Error when using import statement with absolute path on Windows.

v3.2.0

17 Jul 11:28
v3.2.0
950e6ee
Compare
Choose a tag to compare

Features

  • Add option useCurrentGlobal to pass all the available variable from the current global (or globalThis) into the context.
  • Add curried functions createRequireFromString, createImportFromString and createImportFromStringSync.

v3.1.4

23 Dec 23:57
v3.1.4
60fbf27
Compare
Choose a tag to compare

Bug Fixes

  • import.meta.url is incorrectly set to path instead of URL string in importFromString.

Chores

  • Bump dependencies. Note that esbuild 0.14.4 adjusted its handling of default exports and the __esModule marker to improve compatibility with Webpack and Node, which may cause some changes when transforming the code from ES modules to CommonJS modules.

v3.1.3

27 Nov 15:56
v3.1.3
fe07486
Compare
Choose a tag to compare

Bug Fixes

  • Absolute path import on Windows such as C:\foo could not be resolved.

Chores

  • Bump dependencies.

v3.1.2

07 Nov 12:35
Compare
Choose a tag to compare

Chores

  • Bump and unpin dependencies.

v3.1.1

28 Aug 16:23
Compare
Choose a tag to compare

Fixes

  • In the previous versions when using import statement and dynamic import() expression, the specifier would not be resolved correctly if used on Windows and the path starts with posix path separator.

Chores

  • Bump dependency esbuild from 0.12.22 to 0.12.24

v3.1.0

21 Aug 16:27
Compare
Choose a tag to compare
  • Add new optional option dirname to specify the directory path for resolving relative path require or import.
  • Add support for dynamic import() expression.
  • Fix problem when using import statement of ES modules.

v3.1.0-0...v3.1.0

v3.1.0-0

16 Aug 00:20
Compare
Choose a tag to compare
v3.1.0-0 Pre-release
Pre-release
  • Fix support using in ES module scope.
    Execute node with --experimental-vm-modules command flag to enable this.
  • Add new optional option dirname to specify directory path when resolving relative path import.

v3.0.1...v3.1.0-0

v3.0.1

09 Aug 12:06
Compare
Choose a tag to compare

v3.0.0...v3.0.1