dart_node_core library
Core JS interop utilities for Dart JS Framework
A spawned child process with typed streams.
Extension methods FP style transformations
ObjectExtensions
on T
Extension methods FP style transformations
Default retry policy: 3 attempts, 50ms base, 2x backoff.
Get the console object
no setter
require
→ JSFunction
Get Node's require function
no setter
Log to console.error (stderr)
consoleLog(String message)
→ void
Log to console (stdout)
getGlobal(String name)
→ JSAny?
Get a value from the global JavaScript context
requireModule(String module)
→ JSAny
Require a Node module
spawn(String command, List<String> args, {bool shell = false})
→ Process
Spawn a child process.
withRetry<T>(RetryPolicy policy, bool isRetryable(String error), Result<T, String> operation(), {void onRetry(int attempt, String error, int delayMs)?})
→ Result<T, String>
Execute operation with retry on transient errors.
RetryPolicy
= ({double backoffMultiplier, int baseDelayMs, int maxAttempts})
Retry policy configuration.