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

Enable devtools in prod. mode #1247

Closed
fguisso opened this issue Jul 28, 2020 · 2 comments
Closed

Enable devtools in prod. mode #1247

fguisso opened this issue Jul 28, 2020 · 2 comments

Comments

@fguisso
Copy link

fguisso commented Jul 28, 2020

Version

6.0.0-beta.1

Browser and OS info

Firefox

Steps to reproduce

https://codedharma.com/posts/force-vue-devmode/
Tested in various vue apps without devetools = true

What is expected?

Don't enable devtools

What is actually happening?

devtools works


This issue is just to clarify if devtools needs to work or not in prod. mode.

Questions that we need to awnser:

  • Why disable devtools in prod. mode?
  • Today we can disable in prod. mode but there is a bypass with a single variable, this means that the API of devtools is loaded every time, is this correct?
@iChenLei
Copy link

Vue3 change the devtools logic flow, look for this comment #1308 (comment)

Summary

Vue2 have this problem, Vue3 have no problem. And I also don't know why we need disbale devtools in production, React didn't do it but nothing happened.

Today we can disable in prod. mode but there is a bypass with a single variable, this means that the API of devtools is loaded every time, is this correct?

   var devtools = inBrowser && window.__VUE_DEVTOOLS_GLOBAL_HOOK__;

  if (devtools) { ***

me: If user don't install vue-devtools, this check will failed, don't need worry it。If you care about security just remember Frontend code is untrustworthy , Backend need do strictly auth check

@Akryum
Copy link
Member

Akryum commented Jan 29, 2021

Duplicate of #1321

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

No branches or pull requests

3 participants