Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

219
Vistas
How can i prevent them from entering to an address? (express)

I am using /style for style.css and am using this code;

app.get("/style", (req, res) => res.sendFile(__dirname + "/assets/style.css"))

I don't want them to enter to /style address and steal styles, so i want people to get an error that they enter the /style address. How can i do?

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

There is no difference between a URL in <link rel="stylesheet" url=.. and a URL that the user enters in the browser address bar.

Both are endpoints that the browser needs to GET. You can put your whole app behind an authenticated endpoint. But once the client is authenticated and the page is rendered, the users may use dev tools to see your styles.

As an alternative you can use tools to minimize and obfuscate the styles. It makes sense for minification and optimization purposes, but not for protecting the sources. I would also consider what you are trying to protect (CSS styling is not a trade secret and you can copyright your logo/brand style to protect it).

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda