Skip to content

config query string sometimes removed after clicking "Build" button #85

@szhsin

Description

@szhsin

Description:

When clicking the Build button, the config query string in the URL is sometimes removed unexpectedly. This doesn’t happen consistently—I'd estimate it occurs around 50% of the time.

The issue seems to occur more reliably when:

  • The URL includes both config and bundle query strings.
  • The Build button is clicked while the initial auto-build (triggered on page load) is still in progress.

I've attached a video to demonstrate the behavior. Please watch the Chrome address bar closely after clicking the Build button.

Here’s an example link to reproduce the issue: https://bundlejs.com/?q=%40szhsin%2Freact-accordion&treeshake=%5B*%5D&config=%7B%22esbuild%22%3A%7B%22external%22%3A%5B%22react%22%2C%22react-dom%22%5D%7D%7D&bundle

Impact:

Because the config query string is removed, the bundle size calculation is incorrect. For example:

  • With the config query string, the bundle size is 2.92 kB (gzip)
  • Without the config query string, the bundle size jumps to 6.11 kB (gzip)

Expected Behavior:

The config query string should remain in the URL after clicking the Build button.

bundlejs.mov

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions