Skip to content
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

Eliminates circular dependency on timer modules. #402

Open
1 task
mo36924 opened this issue Jan 25, 2025 · 0 comments
Open
1 task

Eliminates circular dependency on timer modules. #402

mo36924 opened this issue Jan 25, 2025 · 0 comments
Labels
enhancement New feature or request

Comments

@mo36924
Copy link

mo36924 commented Jan 25, 2025

Describe the feature

The timers/promises module has circular dependency.

The following warning is output when building with rollup.
(!) Circular dependency
node_modules/unenv/runtime/node/timers/promises/index.mjs -> node_modules/unenv/runtime/node/timers/internal/scheduler.mjs -> node_modules/unenv/runtime/node/timers/promises/index.mjs

import { setTimeout, setImmediate } from "node:timers/promises";

I think this problem can be solved by modifying the above as follows.

import { setTimeoutFallbackPromises as setTimeout } from "./set-timeout";
import { setImmediateFallbackPromises as setImmediate } from "./set-immediate";

Additional information

  • Would you be willing to help implement this feature?
@mo36924 mo36924 added the enhancement New feature or request label Jan 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant