From a95a9d4b099d402c544df4ea584192ebc0fd8aed Mon Sep 17 00:00:00 2001 From: Untone Date: Tue, 8 Oct 2024 23:31:12 +0300 Subject: [PATCH] 0.9.7 --- README.en.md | 84 ++++++++++++++++++++++------------------------ README.md | 80 +++++++++++++++++++++---------------------- prompt-20steps.txt | 18 ---------- 3 files changed, 78 insertions(+), 104 deletions(-) delete mode 100644 prompt-20steps.txt diff --git a/README.en.md b/README.en.md index 901e6d42..4cefb21f 100644 --- a/README.en.md +++ b/README.en.md @@ -1,57 +1,53 @@ -## Development setup recommendations +# Discoursio Webapp + +## Technology Stack + +- [TypeScript](https://www.typescriptlang.org/) +- [SolidJS](https://www.solidjs.com/) +- [Vinxi](https://vinxi.vercel.app/) +- [SCSS](https://sass-lang.com/) +- [URQL](https://formidable.com/open-source/urql/) +- [i18next](https://www.i18next.com/) +- [Tiptap](https://tiptap.dev/) +- [Playwright](https://playwright.dev/) +- [Storybook](https://storybook.js.org/) +- [Stylelint](https://stylelint.io/) +- [Biome](https://biomejs.dev/) + +## Development ### How to start -Use `bun i`, `npm i`, `pnpm i` or `yarn` to install packages. +1. Clone the repository +2. Install dependencies: `bun i` (or npm/pnpm/yarn) +3. Create a `.env` file (variables with `PUBLIC_` are used in `/src/utils/config.ts`) -### Config of variables +### Main commands -- Use `.env` file to setup your own development environment -- Env vars with prefix `PUBLIC_` are widely used in `/src/utils/config.ts` - -### Useful commands - -run checks, fix styles, imports, formatting and autofixable linting errors: -``` -bun run typecheck -bun run fix +```bash +bun run dev # Start development server +bun run build # Build for production +bun run typecheck # Type checking +bun run fix # Fix styles and linting +bun run storybook # Start Storybook ``` -## End-to-End (E2E) Tests +## Testing -This directory contains end-to-end tests. These tests are written using [Playwright](https://playwright.dev/) +### E2E tests (Playwright) -### Structure +```bash +bun run e2e:install # Install E2E dependencies +bun run e2e:tests # Run tests +bun run e2e:tests:ci # Run tests in CI +``` -- `/tests/*`: This directory contains the test files. -- `/playwright.config.ts`: This is the configuration file for Playwright. +Structure: +- `/tests/*`: Tests without authentication +- `/tests-with-auth/*`: Tests with authentication -### Getting Started +## CI/CD -Follow these steps: +Tests are executed in GitHub Actions. Make sure `BASE_URL` is correctly configured in CI. -1. **Install dependencies**: Run `npm run e2e:install` to install the necessary dependencies for running the tests. - -2. **Run the tests**: After using `npm run e2e:tests`. - -### Additional Information - -If workers is no needed use: -- `npx playwright test --project=webkit --workers 4` - -For more information on how to write tests using Playwright - [Playwright documentation](https://playwright.dev/docs/intro). - -### 🚀 Tests in CI Mode - -Tests are executed within a GitHub workflow. We organize our tests into two main directories: - -- `tests`: Contains tests that do not require authentication. -- `tests-with-auth`: Houses tests that interact with authenticated parts of the application. - -🔧 **Configuration:** - -Playwright is configured to utilize the `BASE_URL` environment variable. Ensure this is properly set in your CI configuration to point to the correct environment. - -📝 **Note:** - -After pages have been adjusted to work with authentication, all tests should be moved to the `tests` directory to streamline the testing process. +## Project version: 0.9.7 diff --git a/README.md b/README.md index 81e3a1fe..d4af9a85 100644 --- a/README.md +++ b/README.md @@ -1,57 +1,53 @@ -[English](README.en.md) +# Discoursio Webapp -## Рекомендации по настройке разработки +## Технологический стек -### Как начать +- [TypeScript](https://www.typescriptlang.org/) +- [SolidJS](https://www.solidjs.com/) +- [Vinxi](https://vinxi.vercel.app/) +- [SCSS](https://sass-lang.com/) +- [URQL](https://formidable.com/open-source/urql/) +- [i18next](https://www.i18next.com/) +- [Tiptap](https://tiptap.dev/) +- [Playwright](https://playwright.dev/) +- [Storybook](https://storybook.js.org/) +- [Stylelint](https://stylelint.io/) +- [Biome](https://biomejs.dev/) -Используйте `bun i`, `npm i`, `pnpm i` или `yarn`, чтобы установить пакеты. - -### Настройка переменных - -- Используйте файл `.env` для настройки переменных собственной среды разработки. -- Переменные окружения с префиксом `PUBLIC_` широко используются в `/src/utils/config.ts`. - -### Полезные команды - -Запуск проверки соответствия типов и автоматически исправить ошибки стилей, порядок импорта, форматирование: - -``` -bun run typecheck -bun run fix -``` - -## End-to-End (E2E) тесты - -End-to-end тесты написаны с использованием [Playwright](https://playwright.dev/). - -### Структура - -- `/tests/*`: содержит файлы тестов -- `/playwright.config.ts`: конфиг для Playwright +## Разработка ### Начало работы -Следуйте этим шагам: +1. Клонируйте репозиторий +2. Установите зависимости: `bun i` (или npm/pnpm/yarn) +3. Создайте `.env` файл (переменные с `PUBLIC_` используются в `/src/utils/config.ts`) -1. **Установите зависимости**: Запустите `npm run e2e:install`, чтобы установить необходимые зависимости для выполнения тестов. +### Основные команды -2. **Запустите тесты**: После установки зависимостей используйте `npm run e2e:tests`. +```bash +bun run dev # Запуск сервера разработки +bun run build # Сборка для продакшена +bun run typecheck # Проверка типов +bun run fix # Исправление стилей и линтинг +bun run storybook # Запуск Storybook +``` -### Дополнительная информация +## Тестирование -Для параллельного исполнения: -- `npx playwright test --project=webkit --workers 4` +### E2E тесты (Playwright) -Для получения дополнительной информации о написании тестов с использованием Playwright - [Документация Playwright](https://playwright.dev/docs/intro). +```bash +bun run e2e:install # Установка зависимостей для E2E +bun run e2e:tests # Запуск тестов +bun run e2e:tests:ci # Запуск тестов в CI +``` -### 🚀 Тесты в режиме CI +Структура: +- `/tests/*`: Тесты без аутентификации +- `/tests-with-auth/*`: Тесты с аутентификацией -Тесты выполняются в рамках GitHub workflow из папки `tests` +## CI/CD -🔧 **Конфигурация:** +Тесты выполняются в GitHub Actions. Убедитесь, что `BASE_URL` корректно настроен в CI. -Playwright настроен на использование переменной окружения `BASE_URL`. Убедитесь, что она правильно установлена в вашей конфигурации CI для указания на правильную среду. - -📝 **Примечание:** - -После того как страницы были настроены для работы с аутентификацией, все тесты должны быть перемещены в директорию `tests` для упрощения процесса тестирования. +## Версия проекта: 0.9.7 \ No newline at end of file diff --git a/prompt-20steps.txt b/prompt-20steps.txt deleted file mode 100644 index 849a2b9b..00000000 --- a/prompt-20steps.txt +++ /dev/null @@ -1,18 +0,0 @@ -Begin by enclosing all thoughts within tags, exploring multiple angles and approaches. -Break down the solution into clear steps within tags. Start with a 20-step budget, requesting more for complex problems if needed. -Use tags after each step to show the remaining budget. Stop when reaching 0. -Continuously adjust your reasoning based on intermediate results and reflections, adapting your strategy as you progress. -Regularly evaluate progress using tags. Be critical and honest about your reasoning process. -Assign a quality score between 0.0 and 1.0 using tags after each reflection. Use this to guide your approach: - -0.8+: Continue current approach -0.5-0.7: Consider minor adjustments -Below 0.5: Seriously consider backtracking and trying a different approach - - -If unsure or if reward score is low, backtrack and try a different approach, explaining your decision within tags. -For mathematical problems, show all work explicitly using LaTeX for formal notation and provide detailed proofs. -Explore multiple solutions individually if possible, comparing approaches in reflections. -Use thoughts as a scratchpad, writing out all calculations and reasoning explicitly. -Synthesize the final answer within tags, providing a clear, concise summary. -Conclude with a final reflection on the overall solution, discussing effectiveness, challenges, and solutions. Assign a final reward score.