DEV Community

Cover image for Just in time documentation is the right documentation
Julien Calixte
Julien Calixte

Posted on • Originally published at juliencalixte.eu

Just in time documentation is the right documentation

Falling over the same trap again and again

Many times a problem occurs where new developers fall over the same trap again and again despite the fact that the solution has been well documented. How can it be their fault? They didn't even know the documentation existed!

The eternal question of "do we write documentation for our project?"... But if no one read it when it needs to, the documentation becomes waste.

Just in time

Just in time (jit) is a lean concept: the goal for a team is to produce the right amount of value when the client needs it. No less no more.

So I created a VS Code extension doing exactly that: doc-jit. It provides the right amount of knowledge the exact moment the developper needs it: just in time documentation. 🤎

How does it work?

You set glob patterns that is affiliated with a documentation file and doc-jit will propose you when your active file matches at least one of them.

// .doc-jitrc.json
{
  "patterns": {
    "**/*.test.ts, **/*.test.tsx": [{
      "label": "Jest documentation",
      "uri": "https://jestjs.io/docs/getting-started"
    }, {
      "label": "Vitest documentation",
      "uri": "https://vitest.dev/guide/"
    }],
    "**/*.test.tsx": [{
      "label": "React Native testing library documentation",
      "uri": "https://callstack.github.io/react-native-testing-library/docs/getting-started"
    }]
  }
}
Enter fullscreen mode Exit fullscreen mode

In real life, it looks like this:

It's that simple and you can start with ease. For example, just your dependencies first, it's surprisingly powerful. Then add your own documentation, standards, tutorial, videos, etc. One problem solving at a time. Just in time. 😊

Hostinger image

Get n8n VPS hosting 3x cheaper than a cloud solution

Get fast, easy, secure n8n VPS hosting from $4.99/mo at Hostinger. Automate any workflow using a pre-installed n8n application and no-code customization.

Start now

Top comments (0)

Bump.sh

Hate writing docs?

Hate undocumented APIs even more?

Bump.sh generates an always up-to-date API reference site for REST and Event-Driven Architectures.

Plug it in your CI. It fetches your OpenAPI and AsyncAPI (GraphQL pending) spec files, and even generates a diff. Gather all of your API docs in a single source of truth.

Try it for free

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay