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

Pinia HMR in Vite doesn't work with Quasar CLI Vite #16709

Closed
yu0A opened this issue Dec 15, 2023 · 5 comments
Closed

Pinia HMR in Vite doesn't work with Quasar CLI Vite #16709

yu0A opened this issue Dec 15, 2023 · 5 comments

Comments

@yu0A
Copy link

yu0A commented Dec 15, 2023

What happened?

Pinia HMR in Vite doesn't work with Quasar CLI

What did you expect to happen?

Pinia supports HMR to keep previous states. See https://pinia.vuejs.org/cookbook/hot-module-replacement.html

Reproduction URL

https://github.com/yu0A/vue_quasar_admin/tree/main

How to reproduce?

Deploy this project
Go to http://localhost:9000/#/pythonWangLuoDaoRu
Click "执行" button, where you can see the text on the the right textfield can change.
Trigger HMR, then click "执行" button, where you can see the text on the the right textfield cannot change.

Flavour

Quasar CLI with Vite (@quasar/cli | @quasar/app-vite)

Areas

Quasar CLI Commands/Configuration (@quasar/cli | @quasar/app-webpack | @quasar/app-vite)

Platforms/Browsers

No response

Quasar info output

No response

Relevant log output

No response

Additional context

No response

Copy link

Hi @yu0A! 👋

It looks like you provided an invalid or unsupported reproduction URL.
Do not use any service other than Codepen, jsFiddle, StackBlitz, Codesandbox, and GitHub.
Make sure the URL you provided is correct and reachable. You can test it by visiting it in a private tab, another device, etc.
Please edit your original post above and provide a valid reproduction URL as explained.

Without a proper reproduction, your issue will have to get closed.

Thank you for your collaboration. 👏

@pdanpdan
Copy link
Collaborator

pdanpdan commented Dec 15, 2023

Did you implement what is written on the page you referenced?
If you did please provide a reproduction and we'll reopen.

@yu0A
Copy link
Author

yu0A commented Dec 15, 2023

I just uploaded a Quasar CLI Vite project so that you can reproduce this bug.
vue_quasar_admin

How to reproduce?

  1. Deploy this project
  2. Go to http://localhost:9000/#/pythonWangLuoDaoRu
  3. Click "执行" button, where you can see the text on the the right textfield can change.
  4. Trigger HMR, then click "执行" button, where you can see the text on the the right textfield cannot change.

@pdanpdan
Copy link
Collaborator

@yu0A
Copy link
Author

yu0A commented Dec 20, 2023

That snippet works. Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants