function-location
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

Description

You can retrieve the path of a class or function using this library, and it supports not only node command but also ts-node.

Installation

npm install function-location

Usage

import { locateV8 } from 'function-location';

class TestClass {
}

function TestFunction() {
}

locateV8(TestClass);
locateV8(TestFunction);

Return Value

The locateV8() function returns the source file path of the currently executing function as a string.

License

This library is licensed under the MIT license.

/function-location/

    Package Sidebar

    Install

    npm i function-location

    Weekly Downloads

    1

    Version

    1.0.0

    License

    MIT

    Unpacked Size

    169 kB

    Total Files

    7

    Last publish

    Collaborators

    • nhahan