Skip to content

fix: Updated the CSS file path generation logic in prodExposePlugin t… #663

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jan 14, 2025

Conversation

Skywang16
Copy link

…o correctly handle the base URL.

Description

This PR fixes a bug introduced in the previous PR , where the CSS file paths were not correctly handled when the Vite base configuration was not used. The current PR addresses this by ensuring proper handling of the base URL for CSS files.

Additional context


What is the purpose of this pull request?

  • Bug fix
  • New Feature
  • Documentation update
  • Other

Before submitting the PR, please make sure you do the following

  • Read the Code of Conduct and follow the Commit Convention guidelines.
  • Check that there isn't already a PR that solves the problem the same way to avoid creating a duplicate.
  • Provide a description in this PR that addresses what the PR is solving, or reference the issue that it solves (e.g. fixes #123).
  • Ideally, include relevant tests that fail without this PR but pass with it.

const href = [baseUrl, assetsDir, cssPath].filter(Boolean).join('/');
let href = ''
const baseUrl = base || curUrl
console.log(baseUrl)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is this console.log necessary?

Copy link
Author

Choose a reason for hiding this comment

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

Sorry, it was left from debugging. I'll remove it.

@Jiannan-dev Jiannan-dev merged commit 7baff37 into originjs:main Jan 14, 2025
8 checks passed
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.

3 participants