From 1de9106db6b10934c5d0a73b1f32b61512ca8925 Mon Sep 17 00:00:00 2001 From: mazuh Date: Sun, 25 Feb 2024 16:29:37 -0300 Subject: [PATCH] debug script, add more docs --- README.md | 35 +++++++++++++++++++++++++---------- package.json | 2 +- 2 files changed, 26 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index c9a2c76..8e9d746 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ Postmaiden is an application for testing and documenting HTTP APIs, with straightforward usability, made for developers. -## Setting up +## Setting up locally Having Node 20 installed and in use: @@ -11,24 +11,39 @@ Having Node 20 installed and in use: npm install ``` -And then: +Then the development instance: ``` npm run dev ``` +Now open the application in your browser following the output URL. + +And that's it. There's really no server, by default nobody is intercepting your requests here. + +For core development, there are some useful testing scripts: + +- `npm t` to run all tests, including a full report of coverage and test names. +- `npm run test:watch -- src/example/thing.test.tsx` to run only a specific test file, + and keep running again after each file change. +- `npm run test:debug -- src/example/thing.test.tsx` to run only a specific test file, + but displaying more `console.log` stuff and almost unlimited RTL `screen.debug()`. + ## Non-functional Requirements - Offline-first for free plan features, - powered by [OPFS](https://developer.mozilla.org/en-US/docs/Web/API/File_System_API/Origin_private_file_system) -- Desktop-first interface, but decently responsive -- Chrome and Firefox support -- Components bootstrapped by [Shadcn UI](https://ui.shadcn.com/) -- CSS tool is [Tailwind](https://tailwindcss.com/docs/) + powered by [OPFS](https://developer.mozilla.org/en-US/docs/Web/API/File_System_API/Origin_private_file_system). +- Mainly desktop interface, widths greater than 900px. +- Chrome and Firefox support. +- Tech stack is [React 18](https://react.dev/reference/react) + with TypeScript and [Testing Library](https://testing-library.com/docs/react-testing-library/cheatsheet), + bundled with [Vite](https://vitejs.dev/guide/why.html). +- Components bootstrapped by [Shadcn UI](https://ui.shadcn.com/docs). +- CSS tool is [Tailwind](https://tailwindcss.com/docs/). - Icons by [Font Awesome](https://fontawesome.com/search?o=r&m=free), - free and individual imports -- Serverless cloud infrastructure -- Reasonable test coverage on each feature + but specifically free and React individual imports. +- Serverless cloud infrastructure. +- Reasonable test coverage on each feature. ## License diff --git a/package.json b/package.json index abd3473..98f0c97 100644 --- a/package.json +++ b/package.json @@ -10,7 +10,7 @@ "lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0", "test": "jest --ci --coverage --verbose --silent=true", "test:watch": "jest --silent=true --watch", - "test:verbose": "DEBUG_PRINT_LIMIT=9999999 npm run test -- --silent=false", + "test:debug": "DEBUG_PRINT_LIMIT=9999999 jest --silent=false", "preview": "vite preview" }, "dependencies": {