DEV Community

Cover image for The rfc Snippet That Wouldn’t Work — And What I Learned
Usama
Usama

Posted on

The rfc Snippet That Wouldn’t Work — And What I Learned

Today, I was trying something simple — just type rfc and have my React component snippet expand automatically.

But nothing happened. I typed rfc… nothing.

I checked my snippet JSON. Everything looked correct. The file was valid. Yet the snippet refused to expand. My frustration peaked. 😭

And at that point… I just fell asleep.


Morning Realization

When I woke up, I looked at it again. Maybe stepping away would help. That’s when it clicked:

  • The file was .jsx — but VS Code wasn’t recognizing it properly.
  • IntelliSense and quick suggestions were turned off.
  • The snippet itself was fine, the problem was editor settings and context.

How I Fixed It

Step by step:

  1. Turned on Quick Suggestions
  2. Enabled Snippet Suggestions
  3. Enabled Tab Completion
  4. Restarted VS Code

Finally, I typed rfc and pressed Tab — and it worked! 🥲

function Main() {
  return (
    <div>

    </div>
  );
}

export default Main;
Enter fullscreen mode Exit fullscreen mode

What I Learned

  • BF (Before Fix): frustration, confusion, wasted time
  • AF (After Fix): satisfaction, control, and relief

Lesson: never just look at the surface of a problem. Check the full context — file type, editor settings, suggestions, everything.


💡 Small editor settings can make a huge difference. Sometimes, the problem isn’t your code — it’s your tools.

Top comments (0)