-
-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
More runtime compatibility #28
Comments
The only way I can think of to fix support this is to use an |
Yes, when my packages can target Node.js 16 as then there's a native |
I understand why Remove |
I'm not interested in making breaking changes to I have outlined the solution in #28 (comment) |
I too had to polyfill node Imho, |
We use Octokit to interact with the GitHub API. This switches from the `octokit` package to the more specific `@octokit/rest`, which avoids a dependency on `@octokit/webhooks`. Avoiding this dependency is good because it in turns depends on `clean-stack`, which doesn't play nicely in all JS runtimes - see sindresorhus/clean-stack#28. This cleans up at least the immediate cause of #25.
We use Octokit to interact with the GitHub API. This switches from the `octokit` package to the more specific `@octokit/rest`, which avoids a dependency on `@octokit/webhooks`. Avoiding this dependency is good because it in turns depends on `clean-stack`, which doesn't play nicely in all JS runtimes - see sindresorhus/clean-stack#28. This cleans up at least the immediate cause of #25.
I think solving this issue for the browser is easy: - import os from 'os';
+ import os from './os'; Then have // os.js
export {default} from 'os'
// os-browser.js
export default {homedir: ''}; The only problem is that bundler compatibility is spotty and I'm not sure about the modern equivalent of the Edit: is it I think I've seen this pattern being used with the
Info: Node 14 EOL is May 2023 |
This new
|
It's up to Jest to support Node.js features. |
For anyone else ending up here: The Jest issue is tracked in jestjs/jest#12270, there seem to be workarounds available. |
p-*
function is useful, thank you for your great work.Recently I had some trouble when I use them in some non
node.js
runtime, without bundler.The error cause by:
p-*
-> https://github.com/sindresorhus/aggregate-error -> https://github.com/sindresorhus/clean-stack/blob/main/index.js#L1There is no
os
module in nonnode.js
runtime.So, it's possible to stop using
aggregate-error
inp-*
?The text was updated successfully, but these errors were encountered: