Learn More

Try out the world’s first micro-repo!

Learn More

Pieces User Stories: Store your custom code

Pieces User Stories: Store your custom code

In the three years since Liam began teaching himself to code, he’s experimented with nearly every developer tool on the internet— including Pieces. While it seemed like a nice-to-have when he first downloaded it, over time, Pieces transformed his workflow. “Now months into my Pieces journey, the app has become more and more useful for me every day.”

There are three main ways that Liam uses Pieces: to reuse code that he’s written or customized to his projects, to retain knowledge as part of his active learning process, and to quickly find code that he’s saved over time.

“The traditional workflow I had before I was using Pieces was using extensions that would give me very rough scaffolding for what I wanted to accomplish,” says Liam. “For example, I would punch in a keyboard shortcut and then I'd get a really bare bones component for React. But with Pieces, I can have things implemented in the component, and then save that as a snippet and reuse that custom code. That, to me, is way more powerful than just getting some generic library or generic snippet collection and then having to constantly tweak and readjust it.”

An HTML snippet in Pieces for Developers.

Saving custom code is already huge for Liam, but easily re-using it is even bigger. “Where Pieces really shines is that I can just insert these snippets into my Flutter app and then do some small tweaks and have my custom snippets instantly display the widgets I want. Being able to insert my code from an easy right-click menu or from a tree view in my editor makes my life a lot simpler.”

The joy of coding keeps Liam actively learning new language and frameworks. These days, he’s diving into Flutter and easily extracting code from screenshots with Pieces’ OCR feature. “Where I've had a lot of fun using Pieces lately has been with Flutter and Dart. I've been learning Flutter from online tutorials by following along with YouTube videos. With YouTube videos, oftentimes it's easy to fall behind in terms of what the person on screen is doing with code. One of the ways I've been using Pieces is to utilize screenshots of things that I want to retain from those tutorials.”

And he’s no stranger to coding tutorials. Liam just started following a 36-hour how-to and has been learning with Free Code Camp and Codewars for years, leading him to develop an impressively extensive folder system to try and document what he’s learned. But, quickly referencing code from weeks or months ago was a major time suck until he tried Pieces.

“I used to have to look through my giant folder of all the solved challenges I've done, and now I can just search Pieces and reference them way more easily. The fact that I can add information about them, like the title and the description? That just lets me look for things way faster.”

An example of Liam's file structure.

“Before, if I needed to look up something about, for example, checking object properties, I'd have to remember that I saw this in a Free Code Camp challenge months ago, that it's somewhere in my FreeCodeCamp/JavaScriptdata/playground folder, and that I solved that specific problem in this specific folder. It gets very, very cumbersome to do this after a while, because I have a ton of files and saved solutions,” he explains. “With Pieces, it’s a lot simpler.”

Now, when Liam gets the feeling that he’s written this code before, he starts his search in Pieces. “If I'm coding in JavaScript, I’ll filter things by JavaScript. Going from there, it takes me at most, like 30 seconds to find what I'm looking for. It's pretty fast.”

The speed and ease that Pieces brings to his coding workflow has made Liam a true Pieces advocate; he shares Pieces with every coder he knows. “I really want people to take away the fact that you can code more and decrease the cognitive complexity of coding with Pieces. It’s so much simpler.”

Table of Contents

Flutter

Dart

React

Developer Workflow

More from Pieces
Subscribe to our newsletter
Join our growing developer community by signing up for our monthly newsletter, The Pieces Post.

We help keep you in flow with product updates, new blog content, power tips and more!
Thank you for joining our community! Stay tuned for the next edition.
Oops! Something went wrong while submitting the form.