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

useFetch will be http 400 when navigate from different layout page in old browser and ios app(alipay/qq) #27657

Open
BluesYoung-web opened this issue Jun 17, 2024 · 5 comments

Comments

@BluesYoung-web
Copy link

BluesYoung-web commented Jun 17, 2024

Environment


  • Operating System: Linux
  • Node Version: v20.9.0
  • Nuxt Version: 3.12.2
  • CLI Version: 3.12.0
  • Nitro Version: 2.9.6
  • Package Manager: npm@10.1.0
  • Builder: -
  • User Config: devtools, app, modules, legacy, experimental
  • Runtime Modules: nuxt-vite-legacy@1.2.0
  • Build Modules: -

Reproduction

https://stackblitz.com/edit/github-tphpdd?file=nuxt.config.ts

Describe the bug

When this issue (#24229) was closed, i have try the latest version.

I'm trying to polyfill the old browser(use nuxt-vite-legacy, my old browser is android chrome 56), but found an another bug:

'when navigate to a page which use different layout, useFetch's result will be http 400; but it will be ok when i refresh the page'

And then i test in ios alipay to valid if #24229 fixed, i found http 400 occur again. so, i guess it exsists in ios qq too.

Additional context

ScreenRecord_2024-06-17-10-40-51.mp4

my operate just like this.

Logs

No response

Tasks

No tasks being tracked yet.
Copy link

stackblitz bot commented Jun 17, 2024

Fix this issue in StackBlitz Codeflow Start a new pull request in StackBlitz Codeflow.

@BluesYoung-web BluesYoung-web changed the title useFetch will be http 400 when navigate from diffrent layout page in old broswer and ios app(alipay/qq) useFetch will be http 400 when navigate from different layout page in old broswer and ios app(alipay/qq) Jun 17, 2024
@BluesYoung-web BluesYoung-web changed the title useFetch will be http 400 when navigate from different layout page in old broswer and ios app(alipay/qq) useFetch will be http 400 when navigate from different layout page in old browser and ios app(alipay/qq) Jun 17, 2024
@danielroe
Copy link
Member

In that case, you may need to set responseType: 'json' as one of the options to useFetch. Does that help?

@BluesYoung-web
Copy link
Author

In that case, you may need to set responseType: 'json' as one of the options to useFetch. Does that help?

nop! it dosen't work, still http 400

@danielroe
Copy link
Member

Is there a way to test this on a computer?

@BluesYoung-web
Copy link
Author

Is there a way to test this on a computer?

I just try chrome56 on windows, it occur too.

You can download this version's chrome form here

@danielroe danielroe removed the 3.x label Jun 30, 2024
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