# Node TypeScript Architecture (WIP)

{% hint style="warning" %}
This project and documentation are work in progress
{% endhint %}

![](/files/-M73-Ey7eST9enPsDtCf)

Welcome to NTA! This is an opinionated, newbie-friendly guide to writing Node.js applications in TypeScript. It is accompanied by example code in a [Github repository](https://github.com/jbreckmckye/node-typescript-architecture).

It offers a project structure, naming conventions, example code and recommended habits for building extendable, readable, reliable systems. Although TS is the focus, you can adapt it to plain JavaScript systems too.

You can use this architecture to build backend apps, CLI programs, REST APIs, GraphQL boxes or even use it as part of an SPA.

It's suggested that you read these docs in tandem with the code repository. The repo implements a simple 'community library' application in Express, Postgres (with transactions) and RabbitMQ. I've aimed to write a system that's large enough to illustrate the patterns but still small enough to eyeball fairly quickly.

My hope is that you should be able to get through this guide in well under an hour, even if you're relatively new to writing Node.js apps.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://jbreckmckye.gitbook.io/node-ts-architecture/master.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
