Skip to content
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

Sourcemap failure on Chrome for Vue 2 components with CSS #9830

Closed
7 tasks done
jfparadis-appomni opened this issue Aug 25, 2022 · 0 comments · Fixed by #9914
Closed
7 tasks done

Sourcemap failure on Chrome for Vue 2 components with CSS #9830

jfparadis-appomni opened this issue Aug 25, 2022 · 0 comments · Fixed by #9914
Labels
feat: css p3-minor-bug An edge case that only affects very specific usage (priority)

Comments

@jfparadis-appomni
Copy link

jfparadis-appomni commented Aug 25, 2022

Describe the bug

When css.devSourcemap is false or unset, Chrome fails to display the mapped source for Vue 2 single file components (SFC) that contain CSS. Note that Safari works as expected.

Some limitation in Chrome? Since the template, the javascript, and the CSS are served separately, it seems that Chrome defaults to showing the CSS.

As a workaround, either:

  • Enablecss.devSourcemap does resolve the problem for Chrome art the cost of a larger payload.
  • Do not declare CSS in SFCs.

Reproduction

https://github.com/jf-paradis/demo-vite-issues

System Info

System:
  Binaries:
    Node: 16.16.0 - ~/.nvm/versions/node/v16.16.0/bin/node
    npm: 8.11.0 - ~/.nvm/versions/node/v16.16.0/bin/npm
  npmPackages:
    vite: ^3.0.9 => 3.0.9

Used Package Manager

npm

Logs

No response

Validations

@sapphi-red sapphi-red added feat: css p3-minor-bug An edge case that only affects very specific usage (priority) labels Aug 30, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Sep 14, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feat: css p3-minor-bug An edge case that only affects very specific usage (priority)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants