Skip to content

optimize build process and modernize TypeScript configuration - #22

Merged
xellanix merged 4 commits into
mainfrom
vite-bun
May 21, 2026
Merged

xellanix merged 4 commits into
mainfrom
vite-bun

Conversation

@xellanix

Copy link
Copy Markdown
Owner

Overview

This pull request optimizes the Windows build and distribution process by switching to direct, uncompressed binary distribution and disabling production source maps. Additionally, it modernizes the TypeScript configuration by updating path mappings and upgrading the Bun type definitions.

Key Changes

🚀 Build & Distribution

  • build(windows): distribute raw executable asset
    • Migrated release packaging from an in-memory ZIP archive compression mechanism to direct file distribution using Bun's native I/O primitives (Bun.write).
    • Removed the fflate dependency and synchronous node:fs write methods.
    • Configured the workflow to output uncompressed standalone binaries into a versioned releases directory.
  • build: disable production build source maps
    • Disabled sourcemap generation during the Bun production build process (switching from linked to none).
    • Reduces final binary size and prevents source code exposure in shipped production assets.

🧹 Chore/Refactoring

  • refactor: remove baseUrl and update path mappings
    • Removed deprecated baseUrl configurations from the root and server TypeScript configurations to align with modern module resolution standards (e.g., bundler strategy).
    • Updated server path aliases to use explicit relative paths (../frontend/* and ./*) to preserve resolution behavior based on tsconfig location.
  • chore(packages): bump @types/bun to 1.3.14
    • Upgraded Bun type definitions in development dependencies to match the latest runtime version, ensuring accurate TypeScript compilation and IDE autocompletion.

Version Bump

0.1.0

xellanix added 4 commits May 21, 2026 08:46
Remove the deprecated `baseUrl` configuration from both the root
and server TypeScript configurations. This aligns the workspace
with modern module resolution standards (such as the `bundler`
strategy), ensuring path aliases resolve predictably based on the
tsconfig file location rather than a global base path.

- Remove `baseUrl` references across the repository configs.
- Update server path aliases to use explicit relative paths
  (`../frontend/*` and `./*`) to preserve resolution behavior.
Upgrade the Bun type definitions in development dependencies to match
the latest runtime version. This ensures that TypeScript compilation
and IDE autocompletion accurately reflect any API additions or fixes
introduced up to Bun v1.3.14, preventing potential type-checking
discrepancies during local development and CI builds.
Disable sourcemap generation during the Bun production build process
to reduce the final binary size and prevent source code exposure.

Previously, sourcemaps were set to `linked`, generating external
mapping files that are unnecessary for shipped production assets.
Switching to `none` optimizes the build output and ensures cleaner
deployment artifacts.
Migrate the release packaging logic from an in-memory ZIP archive
compression mechanism to direct file distribution. This leverages Bun's
native I/O primitives to copy and rename the compiled binary directly,
streamlining deployment artifact delivery.

- Remove `fflate` dependency and synchronous `node:fs` write methods.
- Convert `packOutputs` to an asynchronous workflow using `Bun.write`.
- Output uncompressed standalone binaries into a versioned releases
  directory instead of a single zipped archive.
@xellanix
xellanix merged commit cd95a41 into main May 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant