Skip to content

fhellwig/myname

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

myname

Determines the name of a module.

const myname = require('myname')

console.log(myname())

What it does

It gets the name of the parent module (the one requiring the myname module). It then removes itself from the module cache so that the next module will have its own parent as the one that myname returns.

License: MIT

About

Determines the name of a module.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published