Skip to content

Commit 5cca7c5

Browse files
innerdvationsConvly
authored andcommitted
chore: add demos to readme
1 parent 225fd97 commit 5cca7c5

File tree

1 file changed

+46
-0
lines changed

1 file changed

+46
-0
lines changed

README.md

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
- [`.collection()`](#collectionresource)
4444
- [`.single()`](#singleresource)
4545
5. [Debug](#-debug)
46+
6. [Demo Projects](#-demo-projects)
4647

4748
## 🛠 Getting started
4849

@@ -250,3 +251,48 @@ Below is a list of available namespaces to use:
250251
| `strapi:ct:collection` | Logs interactions with collection-type content managers. |
251252
| `strapi:ct:single` | Logs interactions with single-type content managers. |
252253
| `strapi:utils:url-helper` | Logs URL helper utility operations (e.g., appending query parameters or formatting URLs). |
254+
255+
## 🚀 Demo Projects
256+
257+
This repository includes demo projects located in the `/demo` directory to help you get started with using the Strapi SDK. The actual Strapi application is located in the `.strapi-app` directory.
258+
259+
### Demo Structure
260+
261+
- **`.strapi-app`**: This is the main Strapi application used for the demo projects.
262+
- **`demo/demo-node-typescript`**: A Node.js project using TypeScript.
263+
- **`demo/demo-node-javascript`**: A Node.js project using JavaScript.
264+
265+
### Using Demo Scripts
266+
267+
The `package.json` includes several scripts to help you manage and run the demo projects:
268+
269+
- **`demo:seed`**: Seeds the Strapi application with example data. This script also generates `.env` files with API tokens for the `demo-node-typescript` and `demo-node-javascript` projects.
270+
271+
```bash
272+
pnpm run demo:seed
273+
```
274+
275+
- **`demo:seed:clean`**: Cleans the existing data and re-seeds the Strapi application.
276+
277+
```bash
278+
pnpm run demo:seed:clean
279+
```
280+
281+
- **`demo:run`**: Starts the Strapi application in development mode.
282+
283+
```bash
284+
pnpm run demo:run
285+
```
286+
287+
### Adding New Projects
288+
289+
If you add new projects to the `/demo` directory, you will need to update the seed script located at `/demo/.strapi-app/scripts/seed.js` with the new project paths to ensure they are properly configured and seeded.
290+
291+
### Future Plans
292+
293+
We plan to expand the demo projects to include:
294+
295+
- A basic HTML project.
296+
- A Next.js project.
297+
298+
These additions will provide more examples of how to integrate the Strapi SDK into different types of applications.

0 commit comments

Comments
 (0)