@cruise-cli/esm-get-path
TypeScript icon, indicating that this package has built-in type declarations

0.0.2 • Public • Published

@cruise-cli/esm-get-path

TODO: description

Usage

const getPath = require('@cruise-cli/esm-get-path');

// import.meta.url: /root/b/foo.js
getPath(import.meta.url) 
// return '/root/b/foo.js'

getPath(import.meta.url, '..');
// '/root/b'

getPath(import.meta.url, '../package.json'); 
// '/root/b/package.json'

Package Sidebar

Install

npm i @cruise-cli/esm-get-path

Weekly Downloads

0

Version

0.0.2

License

ISC

Unpacked Size

1.42 kB

Total Files

4

Last publish

Collaborators

  • cruise-gt