Back to Explore

floatdrop/require-from-string

GitHub
1 watchersOpen source

Last release: 4/9/2018

require-from-string is a Node utility that loads a module from a JavaScript code string using `requireFromString(code, [filename], [options])`. It is useful for dynamically evaluating module code from text, with options to prepend or append extra module search paths (appendPaths and prependPaths).

Project status

  • The repository appears to be archived upstream (notably marked as archived), with the last upstream push dated 2018-04-09, which suggests it is no longer actively maintained.
  • The apparent update cadence is very infrequent, with a small sequence of updates in 2017 to 2018 (v2.0.0 in 2017-09-16, v2.0.1 in 2017-09-17, v2.0.2 in 2018-04-09).

AI summary generated Today

AI-generated from public sources. May be inaccurate. Report

Recent updates

  • v2.0.2

    4/9/2018

    Release v2.0.2 contains a very small change set. The only runtime modification adds a safety check around accessing `parent.children`, and the README text is corrected.

  • v2.0.1

    9/17/2017

    Release v2.0.1 makes a small internal change to the module cleanup logic in index.js and bumps the package version. There are no release notes provided for this version, so the behavioral impact of the code change is not documented.

  • v2.0.0

    9/16/2017

    Release v2.0.0 was published, but no release notes were provided by the publisher. As a result, there is no documented information about new features, bug fixes, security updates, or potential breaking changes.

  • v1.2.1

    10/1/2016

    Release v1.2.1 contains no publisher-provided release notes. The code diff shows a very small internal change in index.js (how the Node Module constructor is obtained) plus a package.json version bump.

  • v1.2.0

    5/3/2016

    v1.2.0 makes the optional filename argument behave more predictably by normalizing a missing filename to an empty string. It also updates the test suite to assert a more consistent error stack trace when requiring code from a string without providing a filename.

  • v1.1.0

    11/7/2015

    This release introduces an options parameter to `requireFromString` to allow callers to customize Node module resolution paths. It also updates tests and the README to document the new `prependPaths` and `appendPaths` behavior. No release notes were provided by the publisher, so the behavioral changes are not explicitly communicated there.

    Features
  • v1.0.2

    11/6/2015

    v1.0.2 makes a small internal change to how the generated Module instance is constructed when compiling code from a string. There are also test/fixture adjustments that indicate the module parent relationship and exported value expectations changed under the hood.

    Breaking
  • v1.0.1

    11/3/2015

    v1.0.1 updates the core require-from-string implementation and adds a test suite. The main functional change is that module compilation and dependency resolution are now tied to a provided filename (via dirname-based module search paths). Release notes were not provided for this version.

    Features
  • v1.0.0

    7/18/2015

    Release v1.0.0 was published on 2015-07-18, but no release notes were provided by the publisher. As a result, this release cannot be reliably analyzed for specific new features, breaking changes, bug fixes, security updates, or migration steps.