β€’

tech

How maintaining an Open Source project looks like

This is my experience as the creator and maintainer of a popular open source library: how to get started, how to make a successful library, how to maintain it, and what are the results.


Sandro Maglione

Sandro Maglione

Software

Full sprint on Open Source this week for fpdart v2 πŸš€

fpdart at a glance:

  • Flutter Favorite
  • Nearly 500 ⭐️ on Github and 750 πŸ‘ on pub.dev
  • Nearly 3'000 "used by" on Github
fpdart is used by nearly 3000 other open source repositories on Github, and also many more private projects in production
fpdart is used by nearly 3000 other open source repositories on Github, and also many more private projects in production

This is what it takes to be an Open Source maintainer (my perspective πŸ’πŸΌβ€β™‚οΈ)


Choose carefully

First warning for people interested in publishing their own open source project: choose carefully πŸ˜…

My rule before publishing:

Am I seeing myself working and maintaining this project long-term (years) [for free]?

Go ahead only if the answer is absolutely yes πŸ”₯

How fpdart came to be

This is how the stars aligned:

  • I was working on Flutter a lot
  • I was learning functional programming
  • I was using dartz and reading its internal code quite a lot

πŸ‘‰ Will I use Flutter years from now? That's the intention.

πŸ‘‰ Will I use functional programming years from now? Absolutely.

How can I combine these 2 interests? Easy, let's write my own functional programming library in dart πŸͺ„

You can read the full story in The History of fpdart

There is more 🀩

Every week I dive headfirst into a topic, uncovering every hidden nook and shadow, to deliver you the most interesting insights

Not convinced? Well, let me tell you more about it

Where to start

The best tool for an open source maintainer is called prerelease (dev, alpha, beta).

Start by sketching something that works, and push out with a "prerelease" warning πŸ’πŸΌβ€β™‚οΈ

This is where you are allowed to make mistakes, break things, refactor everything (basically the best part of the job 😎).

How to continue

Code is only the first (rather small) step. What's next:

  • Documentation
  • Testing
  • Tutorials
  • User feedback

Important: These are not secondary considerations, these are the core of maintaining and open source project πŸ› οΈ

These steps will take more time than coding itself:

  • Make sure people know how to use the library (documentation)
  • Make sure the library works as expected (testing)

How to end

When the following happens:

  • Everything (nearly) is tested
  • Everything (hopefully) is documented
  • People are using the library with success

Only then it's time to remove the "prerelease" and push out as "stable".

Once in "stable" there is less room for changes: people are using the library in production systems, less time to address breaking changes πŸ’πŸΌβ€β™‚οΈ

And back again

The work continues. More documentation, more tests, more support (issues and user feedback).

Example: fpdart

  • First release 28 May 2021 (3 years ago): just an "experiment"
  • Initial interest: "this looks like a good alternative to dartz" πŸ€”
  • Documentation: tutorial articles and API reference
  • More interest and initial external contributors
  • v1 release: first "stable"
  • Flutter Favorite (2.5 years later)
  • v2 πŸ”œ

Check out the PR preview for fpdart v2


It's not just coding at the end. It looks more like being an entrepreneur πŸ’‘

The path is long, but it can be super rewarding and it will teach you way more than just being a consumer of other packages.

Give it a try (or contribute to existing projects πŸš€)

See you next πŸ‘‹

Start here.

Every week I dive headfirst into a topic, uncovering every hidden nook and shadow, to deliver you the most interesting insights

Not convinced? Well, let me tell you more about it