When I first started building Jottings, I had a pretty specific use case in mind: I wanted a simple place to share my thoughts, observations, and learnings. But after a few weeks of using it myself, I realized something important was missing. As a developer, I spend half my time writing code and the other half understanding code—and I wanted a way to document both without friction.
That's when code snippets became essential to how I use Jottings.
Why Code Snippets Matter
Here's the thing about being a developer: you encounter a lot of solutions. Whether it's a clever regex pattern, a helpful utility function, a configuration snippet that finally made things work, or a code example that cleared up a confusing concept—there's always something worth keeping around.
But where do you keep it? A messy notes app? Random files scattered across your desktop? Buried in old GitHub gists that you'll never find again when you actually need them?
With Jottings, I can share code snippets alongside context. I can add a note explaining why I'm saving this code, when I used it, and what problem it solved. Then I can tag it, search it, and actually find it again.
Markdown Code Blocks in Jottings
Jottings supports standard markdown code blocks with syntax highlighting. You can share code like this:
// Custom debounce function for handling rapid API calls
function debounce(func, delay) {
let timeout;
return function executedFunction(...args) {
const later = () => {
clearTimeout(timeout);
func(...args);
};
clearTimeout(timeout);
timeout = setTimeout(later, delay);
};
}
Just wrap your code in triple backticks with the language identifier, and Jottings will render it with proper syntax highlighting. Supports JavaScript, TypeScript, Python, React, CSS, HTML, Bash, SQL—basically any language you'll need.
The beauty of this approach is that it's simple. You don't need a special code snippet tool. You just write natural language, include code blocks when they're relevant, and hit publish. The syntax highlighting happens automatically.
Organizing Snippets with Tags
One of my favorite Jottings features is the tagging system. When I share a code snippet, I can tag it with the language, framework, or use case. So my React snippets get tagged #react, utility functions get #javascript, and quick fixes get #quick-fix.
This transforms your blog from a chronological dump into an organized reference library. Want to find all your Python scripts? Click the #python tag. Looking for CSS solutions? #css tag has you covered.
I've built up a mental index of patterns I rely on, and having them easily discoverable in Jottings is genuinely useful. No more "I know I solved this once" moments where you spend 30 minutes searching your brain.
Public vs Private Snippets
Here's something important: not all code snippets need to be public.
Some of my most useful code is extremely specific to projects I'm working on, or contains business logic I wouldn't share. For those, Jottings lets me keep snippets private. I get all the benefits of having a searchable, organized code reference without publishing everything to the internet.
I reserve public code snippets for things that:
- Solve a general problem others might encounter
- Demonstrate a technique or pattern worth sharing
- Could genuinely help someone else ship faster
- Don't reveal anything sensitive about my projects
This flexibility means Jottings works equally well as a private reference library for yourself and as a public resource for your audience.
Beyond Just Code: Adding Context
Here's where code snippets in Jottings shine compared to isolated code sharing platforms. You're not just dropping code—you're sharing code with explanation.
I'll write a jot like: "Had to implement a modal dialog that traps focus for accessibility. Here's the pattern I use for keyboard navigation:" Then I include the code, and anyone reading understands not just what the code does, but why it matters and when they'd use it.
This context is invaluable. A code snippet without context is just text. A snippet with explanation becomes a teaching tool.
Using Code Snippets as Personal Reference
Honestly, my biggest use case for code snippets in Jottings isn't even about my audience—it's about me six months from now.
Future Vishal will be grateful when he needs to implement markdown parsing in a new project and can pull up the approach he documented before. Or when he's debugging a subtle TypeScript issue and remembers he saved the solution with a clear explanation of what was wrong.
Your public blog is your memory extended outward. When you document code solutions in Jottings, you're building a searchable, organized personal knowledge base that happens to be visible to others.
A Simple but Powerful Feature
Markdown code blocks might seem like a basic feature—and technically, they are. But in the context of a simple, focused blogging tool like Jottings, they become genuinely useful.
No special syntax to learn. No external code snippet embeds that break when the service goes down. Just clean, portable markdown with syntax highlighting built in.
Whether you're a developer sharing quick tips, a technical writer documenting solutions, or someone building a personal reference library in public, Jottings makes it dead simple to share code alongside your thoughts.
If you're looking for a straightforward place to document code snippets without abandoning the rest of your blogging, give Jottings a try. Create a site, start tagging your snippets, and build a searchable reference that helps you and potentially helps others along the way.
That's what I built it for, and it's honestly one of my favorite ways to use it.