DEV Community

Krishna Tej Ch
Krishna Tej Ch

Posted on

Is it normal that devs get stuck to figure out a solution while using external libraries?

I had this lingering doubt from so long.

Whenever a problem comes up while developing, I could design a solution or at least a starting point to solve the problem. Many times I get stuck in figuring out a solution with a library which we use in the project.

The whole thing of figuring out a solution with a library takes much more time than using my solution. The cons of using my solution is, I had to write a whole method for getting the solution for which the libraries already have an existing functionality.

I wonder many times does it mean I am slow at adopting the solution using an external library. This affects my pridcutivity a lot as I tend to get stuck on trivial issues for hours.

Please share your advice and experiences regarding this.

Latest comments (2)

Collapse
 
moopet profile image
Ben Sinclair

I think the problem comes from wanting to use an existing library for the right reasons:

  • re-use
  • many eyes
  • someone else does the security updates

That sort of thing. It's all good, right? Except in the real world the majority of third-party libraries have incomplete or missing documentation, or documentation written assuming unspecified prior knowledge.

Figuring out how to use a library feels like a problem because in the real world you have to spend time before you find out that the library is actually unsuitable for your purpose or would only work if you rewrote it (defeating the whole point), and your experience of having done this a few million times by now makes you reluctant to spend the time learning yet another API.

Collapse
 
alchermd profile image
John Alcher

I wonder many times does it mean I am slow at adopting the solution using an external library. This affects my pridcutivity a lot as I tend to get stuck on trivial issues for hours.

We tend to be biased in favor of writing our own solutions, so this is normal. I take solace in the fact that when I use a well tested library to solve a problem, the time spent learning the library is definitely shorter than implementing, testing, maintaining etc.. the solution myself.