sindresorhus / capture-stack-trace Goto Github PK
View Code? Open in Web Editor NEWPonyfill for Error#captureStackTrace
License: MIT License
Ponyfill for Error#captureStackTrace
License: MIT License
Hello, is it possible to incorporate the LICENSE file inside the npm package ? Now it's missing. It's implied by MIT license that if licensed under the MIT the source code must be accompanied by full license text. If the license file is not in the npm package a lot of people cannot use it.
Thank you
error:
[1/4] Resolving packages...
[2/4] Fetching packages...
error http://registry.npm.taobao.org/capture-stack-trace/download/capture-stack-trace-1.0.1.tgz: Fetch succeeded for undefined. However, extracting "http://registry.npm.taobao.org/capture-stack-trace/download/capture-stack-trace-1.0.1.tgz" resulted in hash "a6c0bbe1f38f3aa0b92238ecb6ff42c344d4135d", which did not match the requested hash "ed0a1edb87c05d4db1037c5f8f483d8a3b5f0825".
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
Hello, I found that the hash was changed but the version was not recently. So I should change the hash myself.
Error.captureStackTrace()
supports an second param at/fn/subject
function a(fn) {
const o = {}
console.log(Error.captureStackTrace(o, fn))
}
function b(fn = a) { a(fn) }
function c() {
// yields:
// at b (...)
// at c (...)
b()
// yields:
// at c (...)
b(b)
}
Ref on NodeJS (v8):
https://github.com/tapjs/stack-utils/blob/main/index.js#L142
It would be great if capture-stack-trace
would support that too.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.