mirror of
https://github.com/oven-sh/bun
synced 2026-02-13 20:39:05 +00:00
Previously, Bun.build would accept any string as a define key, including invalid JavaScript identifiers like "invalid-name" or "123invalid". This could lead to generated code with syntax errors. Now validates that define keys are valid JavaScript identifiers using js_lexer.isIdentifier() and throws a clear error message when invalid. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>