create-require
Last updated 5 years ago by pi0 .
MIT · Original npm · Tarball · package.json
$ gnpm install create-require 
SYNC missed versions from official npm registry.

create-require

npm version npm downloads Github Actions Codecov

Polyfill for Node.js module.createRequire (<= v12.2.0)

Install

yarn add create-require

npm install create-require

Usage

function createRequire (filename: string | URL): NodeRequire;
const createRequire = require('create-require')

const myRequire = createRequire('path/to/test.js')
const myModule = myRequire('./test-sibling-module')

License

MIT

Current Tags

  • 1.1.1                                ...           latest (4 years ago)

7 Versions

  • 1.1.1                                ...           4 years ago
  • 1.1.0                                ...           4 years ago
  • 1.0.2                                ...           4 years ago
  • 1.0.1                                ...           5 years ago
  • 1.0.0                                ...           5 years ago
  • 0.0.1                                ...           5 years ago
  • 0.0.0                                ...           5 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 3
Last Day 0
Last Week 3
Last Month 0
Dependencies (0)
None
Dev Dependencies (0)
None
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |