- Date -> Temporal: Do not use the native JavaScript
Dateconstructor. All date, time, and timezone operations must utilize theTemporalAPI.Why: The native
Dateobject has legacy API flaws, inconsistent timezone behaviors, and side effects. TheTemporalAPI is a modern standard proposed by TC39 that handles dates, times, and timezones safely and reliably. - node:stream -> Web API stream: Use standard Web API streams instead of Node.js stream modules when processing file uploads, downloads, or buffer piping.
- node:fs -> bun:File: Use the native
bun:FileAPIs (such asBun.file()) and Bun's built-in file system utilities for optimized file reading/writing performance.