Hide Source On Website

I am new to this thing called “Glitch”
I am trying to find a way to hide these files from this thing:
https://gyazo.com/adbc50a0cce9805f004514f25865691e

My Glitch project currently looks like this:
https://gyazo.com/f0c12b7c3a30d0616851a9e906981a10

How can I hide my files from the sources part of the website?

@jsdood, not possible.

why is it not possible

You cannot hide the Sources tab for neither yourself nor users. If you would like to prevent opening of DevTools, you can do something like this:

window.oncontextmenu = () => {
  return false;
};

document.onkeydown = e => {
  if (window.event.keyCode === 123 || e.button === 2) return false;
};
1 Like

but someone could still open it with keys like ctrl shift + i

Then return false; if the keyCode is such.

Hello @jsdood,

You can hide your project’s code from other users in the Glitch editor by making it a private project. You’ll be able to see it but others will not. However, there’s no way to keep people from seeing the code that powers a website. Any code you send as part of a webpage will be accessible via the browser’s devtools. You can run your code on the server if there’s code you need to keep secret.

1 Like