Can we make an attempt to share snippets here directly which we think can be used regularly?
For example, adding shapefile programmatically, or buffer etc.
As Regan said, the best place for snippets is in context of the problem they're built to solve, that is, in answer to a question.
If the snippet is too large to integrate cleanly into an answer there are couple of 3rd party places I know of, no doubt there are others:
For people who do decide to use a snippet service, I would ask that the most relevant part of the code, the keystone idea, be replicated in the answer itself. This provides resilience in the face of broken links and, more importantly, educates. The what and why of a method are it's most important features. The how can be replicated if the principles are known.