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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃悰 BUG: client:only component not visible in development #3739

Closed
1 task done
saravanapriyanm opened this issue Jun 28, 2022 · 6 comments
Closed
1 task done

馃悰 BUG: client:only component not visible in development #3739

saravanapriyanm opened this issue Jun 28, 2022 · 6 comments
Assignees
Labels
- P4: important Violate documented behavior or significantly improves performance (priority) feat: hmr Related to HMR (scope)

Comments

@saravanapriyanm
Copy link

What version of astro are you using?

1.0.0-beta.42

Are you using an SSR adapter? If so, which one?

No

What package manager are you using?

npm

What operating system are you using?

Mac, Windows

Describe the Bug

When running the project with astro dev, client:only component is not visible. After build, in astro preview the component is visible.

Console throws an error:
Uncaught (in promise) TypeError: Failed to fetch dynamically imported module: https://github-jhuzfh-ehssvd--3000.local.webcontainer.io/@fs/home/projects/github-jhuzfh-ehssvd/src/components/accordion

Link to Minimal Reproducible Example

https://stackblitz.com/edit/github-jhuzfh-ehssvd

Participation

  • I am willing to submit a pull request for this issue.
@github-actions github-actions bot added this to Needs Triage in 馃悰 Bug Tracker Jun 28, 2022
@saravanapriyanm
Copy link
Author

saravanapriyanm commented Jun 28, 2022

In stackblitz, change something in index.html to reproduce the bug.

Page refresh seems to work in stackblitz, but not working in local.

client.js and component file seems to be stuck in network forever:

Screenshot 2022-06-28 at 3 15 18 PM

@tony-sull tony-sull added - P4: important Violate documented behavior or significantly improves performance (priority) s1-small feat: hmr Related to HMR (scope) labels Jun 28, 2022
@tony-sull
Copy link
Contributor

Thanks for filing this! Just confirmed locally as well with the latest beta release, looks like our HMR script may need an update to persist the client:only components in HMR

@natemoo-re natemoo-re self-assigned this Jul 7, 2022
@saravanapriyanm
Copy link
Author

Any update on this?

@natemoo-re
Copy link
Member

Sorry for the delay @saravanapriyanm! I am looking at this as we speak.

@natemoo-re
Copy link
Member

I can confirm that this is no longer happening with our latest changes in the astro@1.0.0-rc release candidate!

See that updating both the pages/index.astro file and the components/accordion.jsx file refresh the page as expected. https://stackblitz.com/edit/github-jhuzfh-xp4vv6?file=src%2Fpages%2Findex.astro

If you run into any further issues, please don't hesitate to open another issue!

馃悰 Bug Tracker automation moved this from Needs Triage to Done Aug 4, 2022
@CommanderGL
Copy link

This is happening to me in newer version.

I was trying to make an Iframe that will set src based on id in URL Search Params I moved my JS code to SolidJS component and got this error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
- P4: important Violate documented behavior or significantly improves performance (priority) feat: hmr Related to HMR (scope)
Projects
No open projects
Development

No branches or pull requests

4 participants