Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: clarify the documentation on running examples #4818

Merged
merged 3 commits into from Jan 15, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
13 changes: 11 additions & 2 deletions CONTRIBUTING.md
Expand Up @@ -22,12 +22,21 @@ If you have been assigned to fix an issue or develop a new feature, please follo
- We use [nvm](https://github.com/nvm-sh/nvm) to manage node versions - please make sure to use the version mentioned in `.nvmrc`.
- Run development server using `pnpm run watch`.
- Implement your changes and tests to files in the `src/` directory and corresponding test files.
- To run examples, follow their individual directions.
- To run examples using your local build, be sure to have development server (`pnpm run watch`) running.
- Document your changes in the appropriate doc page.
- Git stage your required changes and commit (see below commit guidelines).
- Submit PR for review.

### Running examples
- Make sure you've installed the dependencies by running `$ pnpm install` in the repo's root directory.
- If you want to run the example against your local changes, run `pnpm run build` in the repo's root directory. Otherwise, it will be run against the latest TanStack Query release.
TkDodo marked this conversation as resolved.
Show resolved Hide resolved
- Run `pnpm run dev` in the selected examples' directory.

#### Note on `examples/react-native`
React Native example requires Expo to work. Please follow the instructions from example's README.md file to learn more.

#### Note on standalone execution
If you want to run an example without installing dependencies for the whole repo, just follow instructions from the example's README.md file. It will be then run against the latest TanStack Query release.

## Online one-click setup

You can use Gitpod (An Online Open Source VS Code like IDE which is free for Open Source) for developing online. With a single click it will start a workspace and automatically:
Expand Down