1 Star 0 Fork 0

animalcoder/Vue

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
stackframe-tests.ts 1.42 KB
一键复制 编辑 原始数据 按行查看 历史
animalcoder 提交于 2020-03-23 09:59 +08:00 . Vue6
/// <reference path="stackframe.d.ts"/>
// Create StackFrame and set properties
var stackFrame = new StackFrame({
functionName: 'funName',
args: ['args'],
fileName: 'http://localhost:3000/file.js',
lineNumber: 1,
columnNumber: 3288,
isEval: true,
isNative: false,
source: 'ORIGINAL_STACK_LINE'
});
stackFrame.functionName; // => "funName"
stackFrame.setFunctionName('newName');
stackFrame.getFunctionName(); // => "newName"
stackFrame.args; // => ["args"]
stackFrame.setArgs([]);
stackFrame.getArgs(); // => []
stackFrame.fileName; // => 'http://localhost:3000/file.min.js'
stackFrame.setFileName('http://localhost:3000/file.js');
stackFrame.getFileName(); // => 'http://localhost:3000/file.js'
stackFrame.lineNumber; // => 1
stackFrame.setLineNumber(325);
stackFrame.getLineNumber(); // => 325
stackFrame.columnNumber; // => 3288
stackFrame.setColumnNumber(20);
stackFrame.getColumnNumber(); // => 20
stackFrame.source; // => 'ORIGINAL_STACK_LINE'
stackFrame.setSource('NEW_SOURCE');
stackFrame.getSource(); // => 'NEW_SOURCE'
stackFrame.isEval; // => true
stackFrame.setIsEval(false);
stackFrame.getIsEval(); // => false
stackFrame.isNative; // => false
stackFrame.setIsNative(true);
stackFrame.getIsNative(); // => true
stackFrame.toString(); // => 'funName(args)@http://localhost:3000/file.js:325:20'
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/animalcoder/Vue.git
git@gitee.com:animalcoder/Vue.git
animalcoder
Vue
Vue
master

搜索帮助