Skip to content

fix(core): respect server.port when replacing <port>#4578

Merged
chenjiahan merged 2 commits intoweb-infra-dev:mainfrom
colinaaa:colin/0217/public-path
Feb 17, 2025
Merged

fix(core): respect server.port when replacing <port>#4578
chenjiahan merged 2 commits intoweb-infra-dev:mainfrom
colinaaa:colin/0217/public-path

Conversation

@colinaaa
Copy link
Copy Markdown
Contributor

Summary

When using Rsbuild without development server(e.g.: rsbuild.initConfig() or rsbuild inspect), the publicPath is not correct since we are using context.devServer?.port || DEFAULT_PORT

This patch fix this to use server.port when needed.

Related Links

A fix of #3098.

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).

@netlify
Copy link
Copy Markdown

netlify Bot commented Feb 17, 2025

Deploy Preview for rsbuild ready!

Name Link
🔨 Latest commit 76518f6
🔍 Latest deploy log https://app.netlify.com/sites/rsbuild/deploys/67b347c7843bd80008dc07ba
😎 Deploy Preview https://deploy-preview-4578--rsbuild.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 59 (🟢 up 15 from production)
Accessibility: 97 (no change from production)
Best Practices: 100 (no change from production)
SEO: 100 (no change from production)
PWA: 60 (no change from production)
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Copy Markdown
Member

@chenjiahan chenjiahan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@chenjiahan chenjiahan enabled auto-merge (squash) February 17, 2025 14:32
@chenjiahan chenjiahan merged commit d5bd6b6 into web-infra-dev:main Feb 17, 2025
@chenjiahan chenjiahan mentioned this pull request Feb 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants