|
| 1 | +# TanStack Query with Orbit.js |
| 2 | + |
| 3 | +A library for using [TanStack Query](https://tanstack.com/query) with [Orbit.js](https://orbitjs.com/). |
| 4 | + |
| 5 | +## Using the library |
| 6 | + |
| 7 | +You can use the library through the packages: |
| 8 | + |
| 9 | +- [`@tanstack-query-with-orbitjs/core`](libs/core) |
| 10 | +- [`@tanstack-query-with-orbitjs/react`](libs/react) |
| 11 | + |
| 12 | +## Examples |
| 13 | + |
| 14 | +- [**Chat app with TanStack Query**](apps/example-chat-app-with-tanstack-query)<br> |
| 15 | + Example chat app using _ONLY_ TanStack Query. For more information, see the [_Results: A concrete example of the problem_](https://danielgiljam.com/degree-thesis/results#a-concrete-example-of-the-problem) chapter in my degree thesis. |
| 16 | +- [**Chat app with TanStack Query and Orbit.js**](apps/example-chat-app-with-tanstack-query-and-orbitjs)<br> |
| 17 | + Modified version of [Chat app with TanStack Query](apps/example-chat-app-with-tanstack-query) which also uses Orbit.js and [`@tanstack-query-with-orbitjs/core`](libs/core). |
| 18 | + |
| 19 | +## Development environment |
| 20 | + |
| 21 | +You need to set up a development environment in order to: |
| 22 | + |
| 23 | +- Develop / contribute to the library |
| 24 | +- Run the examples |
| 25 | + |
| 26 | +### Configuring the development environment the recommended way |
| 27 | + |
| 28 | +The recommended way to set up the development environment is to use [VSCode](https://code.visualstudio.com/) and the [Dev Containers](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) extension and [clone the repository in a container volume](https://code.visualstudio.com/docs/devcontainers/containers#_quick-start-open-a-git-repository-or-github-pr-in-an-isolated-container-volume). This way everything is set up for you automatically. |
| 29 | + |
| 30 | +If you don't want to use VSCode and the Dev Containers extension, read on about configuring the development environment. |
| 31 | + |
| 32 | +### Configuring the development environment manually |
| 33 | + |
| 34 | +1. Install [Node.js](https://nodejs.org/en) v16.13 or newer (the newer, the better). |
| 35 | + |
| 36 | +2. Enable [Corepack](https://nodejs.org/api/corepack.html) so that the correct package manager is used. |
| 37 | + If you installed Node.js using Homebrew, you'll need to install Corepack separately: |
| 38 | + |
| 39 | + ```sh |
| 40 | + brew install corepack |
| 41 | + ``` |
| 42 | + |
| 43 | + Else, Corepack is bundled with Node.js, and to enable it, all you need to do is run the command: |
| 44 | + |
| 45 | + ```sh |
| 46 | + corepack enable |
| 47 | + ``` |
| 48 | + |
| 49 | +3. Install project dependencies by running the following command in the root of your repo. |
| 50 | + ```sh |
| 51 | + pnpm install |
| 52 | + ``` |
0 commit comments