This year we have decided to make our first open source project. It is context menu component for React Native. However right now we don’t want to talk about the component itself but rather talk about what have we learnt by doing it.

Motivation

Why have we decided to make it in first place? We used another library for RN context menu in our application. However it had some issues – we reported some of them, even one pull request but author haven’t so much time to solve them. Of course, he has no obligations to do so – it is open source. As we were digging deeper, it seems that the library would need big overhaul.

Therefore we have decided to remake the library from scratch – just to preserve (and extend) API so that we don’t need big changes in our application. We could make it as internal project but we were curious what does it mean to make open source project. And we wanted to become famous with a high quality library 🙂

Lessons learnt

Let’s be honest – it takes more time to make open source project. You make more tests – 86% coverage against over 60% for our current project. You need to make nice documentation and dozens of examples. It took 30% more time than were our realistic estimations.

Despite our efforts we made errors. We have 10 issues right now in github but I would say only one or two were real errors – rests were some miss configurations or enhancements. But the one was really lame. Always test your library with independent clean project. It was working fine with our included examples and our application as well. However we exported also one file to NPM that had depended on development dependencies and it caused library to fail. And it took us quite long to find out.

This leads to next discovery. Report issues you find when you care for open source. I used to be reluctant to report issues to other open source projects. I was shy, maybe it could be an configuration error. Maybe it was just an improvement and I hadn’t wanted to bother. But right now we see it also from opposite (authors’) perspective. We wanted to get feedback. And that error could have been fixed sooner. Instead we had been just reading that our library is crashing in issue comments of the “original” library.

Conclusion

Was it worth? Well, we believe yes. So far we can’t say that we gained benefits from external contributions like pull requests or even external testing – so far users haven’t found any error that could affect us. But even that increases our confidence that the library works fine. And we believe we made the (open source) world a little bit better at least for 55 people that starred our project on github 🙂

Related Post

Leave a Comment

© 2024 Instea, s.r.o.
All rights reserved. Privacy policy

Contact us

Where to find us

Connect with us