Hiding site codes

people can see site codes like this. Can I hide the appearance of these files in Glitch?

Screenshot_2

There is not way to hide client side code. If you have secrets you do not want users to see, you should put that in the backend (Nodejs, PHP, etc.).

1 Like

You can block right-click to prevent people from going into inspect element, but this is still not safe and inspect element can still be accessed. As @RiversideRocks said, probably best to put it on the backend

3 Likes

There are shortcuts to open this as well.

No, there will never be a way to hide the source code of a front-end website. This is because the source code is sent to the browser so the person accessing your website can actually see the content.

The best you can do is to use uglify or something and don’t emit map files.

I have a Node Login form http-auth.glitch.me
Nobody can see source code unless they’re signed in. Otherwise, there is no way to hide code,

@anon69241012 Wrong URL - I get error

Hmmm… What did I call it? I know it was something like that…

@EddiesTech httpauth.glitch.me I added a dash

thats just this [Template/Tutorial] How to password-protect a static (!) website

1 Like

No, @Wish’s has “access denied” when you click cancel. Mine keeps popping up until the unauthorized user gets annoyed. @Misly


seems to stop showing up after a couple times

I couldn’t guarantee it. I’m working on YOURLS