
Security News
Deno Goes the Way of the Dinosaur
Cloudflare is acquiring Deno’s team, which will provide another year of bug fixes and security updates before ending support for the runtime.
@bun-win32/dwmapi
Advanced tools
Zero-dependency, zero-overhead Win32 DWMAPI bindings for Bun (FFI) on Windows.
Zero-dependency, zero-overhead Win32 DWMAPI bindings for Bun on Windows.
@bun-win32/dwmapi exposes the dwmapi.dll exports using Bun's FFI. It provides a single class, Dwmapi, which lazily binds native symbols on first use. You can optionally preload a subset or all symbols up-front via Preload().
The bindings are strongly typed for a smooth DX in TypeScript.
dwmapi.dll (27 bindings covering Desktop Window Manager composition, blur, thumbnails, and window attributes).structs/Dwmapi.ts with links to Microsoft Docs.Dwmapi.Preload()).types/Dwmapi.ts).bun add @bun-win32/dwmapi
import Dwmapi, { WindowAttribute } from '@bun-win32/dwmapi';
// Optionally bind a subset up-front
Dwmapi.Preload(['DwmIsCompositionEnabled', 'DwmGetWindowAttribute', 'DwmSetWindowAttribute']);
// Check if DWM composition is enabled
const enabledBuf = Buffer.alloc(4);
Dwmapi.DwmIsCompositionEnabled(enabledBuf.ptr);
console.log('Composition enabled:', !!enabledBuf.readInt32LE(0));
// Get the system colorization color
const colorBuf = Buffer.alloc(4);
const opaqueBuf = Buffer.alloc(4);
Dwmapi.DwmGetColorizationColor(colorBuf.ptr, opaqueBuf.ptr);
console.log('Color:', '0x' + colorBuf.readUInt32LE(0).toString(16));
// Enable immersive dark mode on a window (requires a valid HWND)
// const darkMode = Buffer.alloc(4);
// darkMode.writeInt32LE(1, 0);
// Dwmapi.DwmSetWindowAttribute(hwnd, WindowAttribute.DWMWA_USE_IMMERSIVE_DARK_MODE, darkMode.ptr, 4);
[!NOTE] AI agents: see
AI.mdfor the package binding contract and source-navigation guidance. It explains how to use the package without scanning the entire implementation.
Run the included example:
bun run example
Dwmapi.Preload().FAQs
Zero-dependency, zero-overhead Win32 DWMAPI bindings for Bun (FFI) on Windows.
We found that @bun-win32/dwmapi demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.

Security News
Cloudflare is acquiring Deno’s team, which will provide another year of bug fixes and security updates before ending support for the runtime.

Security News
Anthropic’s free OSS Scanner uses Mythos and other Claude models to find open source vulnerabilities and send maintainers reports with proposed fixes.

Security News
On Front Lines’ Early Adopters: CISO podcast, Andrew Becherer shares lessons from Datadog, weighs the long-term costs of AI-built tools, and explains how founders can actually gain a CISO’s trust.