Photo by Becca Tapert on Unsplash

Why your frontend repo is private?

Ok, Let me ask this very brave question. Why in 2020, the pure frontend code repo is still private?

In my opinion, there are no such benefits by keeping frontend code repo in private walls.

1. The output is already public

we generate the build/dist folder by webpack or similar tools. this is the end result of most frontend repo. and this folder is already public.

If anybody can do something by looking at your public frontend repo, she/he can do the same thing by looking at your dist folder too.

By uglifying and other stuff, we just reduce the small probability.

2. Data is precious, it is hidden by API

What exactly we are securing? Data, Server side stuff? All the security stuff goes on Backend APIs. APIs are responsible for security.

Backend APIs can be triggered from console and frontend “display: none” on an unauthorized part is the foolish trick.

3. Advantages when you public your frontend repo.

  1. Others will read the code and the speed of frontend evolution will increase and we can soon reach either “frontend singularity” or “frontend fully defined”.
  2. We all will be super cautious about not putting anything “secret” in the git repo.
  3. Instead of asking “Useless and Complex” algo questions, we can actually assign a real bug for the interview.
  4. Many things annoy on many websites, and I always think, If I can generate a pull request.
  5. maybe you can comment on a few advantages and disadvantages.

I really, don’t know if this ever is possible, but I really don’t see any point in keeping the frontend repo private. Of course, there are server-rendered web apps, which will always remain private and that is okay.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Narendra Sisodiya

Narendra Sisodiya

12+yrs exp. JavaScript Expert. Full Stack Expert. React, Nodejs Mongo AWS, Terraform Pulumi. IITian, Open Source. Currently Software Architect @ Prophecy.io