mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-03 22:37:03 +00:00
Merge pull request #23396 from ajafff/get-caller-file
Add get-caller-file
This commit is contained in:
@@ -0,0 +1,4 @@
|
||||
import getCallerFile = require('get-caller-file');
|
||||
|
||||
let caller: string = getCallerFile();
|
||||
caller = getCallerFile(3);
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
// Type definitions for get-caller-file 1.0
|
||||
// Project: https://github.com/stefanpenner/get-caller-file#readme
|
||||
// Definitions by: Klaus Meinhardt <https://github.com/ajafff>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
declare function getCallerFile(position?: number): string;
|
||||
|
||||
export = getCallerFile;
|
||||
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"esModuleInterop": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"get-caller-file-tests.ts"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Reference in New Issue
Block a user