{"id":22262146,"url":"https://github.com/tyler36/ddev-vitest","last_synced_at":"2025-03-25T13:42:48.364Z","repository":{"id":265002420,"uuid":"894807367","full_name":"tyler36/ddev-vitest","owner":"tyler36","description":"A helper add-on for projects using Vitest","archived":false,"fork":false,"pushed_at":"2024-11-28T02:39:02.000Z","size":50,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-30T12:32:16.833Z","etag":null,"topics":["ddev-get","testing","vitest"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tyler36.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-27T03:01:08.000Z","updated_at":"2025-01-12T13:52:35.000Z","dependencies_parsed_at":"2024-11-27T06:33:41.678Z","dependency_job_id":null,"html_url":"https://github.com/tyler36/ddev-vitest","commit_stats":null,"previous_names":["tyler36/ddev-vitest"],"tags_count":1,"template":false,"template_full_name":"ddev/ddev-addon-template","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tyler36%2Fddev-vitest","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tyler36%2Fddev-vitest/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tyler36%2Fddev-vitest/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tyler36%2Fddev-vitest/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tyler36","download_url":"https://codeload.github.com/tyler36/ddev-vitest/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245473453,"owners_count":20621240,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ddev-get","testing","vitest"],"created_at":"2024-12-03T09:17:50.806Z","updated_at":"2025-03-25T13:42:48.339Z","avatar_url":"https://github.com/tyler36.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![tests](https://github.com/tyler36/ddev-vitest/actions/workflows/tests.yml/badge.svg)](https://github.com/tyler36/ddev-vitest/actions/workflows/tests.yml) ![project is maintained](https://img.shields.io/maintenance/yes/2024.svg)\n\n# ddev-vitest \u003c!-- omit in toc --\u003e\n\n- [What is ddev-vitest?](#what-is-ddev-vitest)\n- [Components of the repository](#components-of-the-repository)\n- [Getting started](#getting-started)\n- [Commands](#commands)\n  - [`ddev vitest`](#ddev-vitest)\n  - [`ddev vitest-ui`](#ddev-vitest-ui)\n- [Auto-start Vitest UI](#auto-start-vitest-ui)\n- [Vite](#vite)\n\n## What is ddev-vitest?\n\n`ddev-vitest` is a helper add-on for DDEV that improves the developer experience for projects using Vitest.\n\n[Vitest](https://vitest.dev/) describes itself as a \"next generation testing framework\", a fast \"Vite-native\" testing framework.\n\n## Components of the repository\n\n- [config.vitest-ui.yaml](config.vitest-ui.yaml): a configuration file that exposes the Vitest UI port.\n- [commands/web/vitest](commands/web/vitest): a helper command for Vitest\n- [commands/host/vitest-ui](commands/host/vitest-ui): a helper command for to launch the Vitest UI site.\n- [install.yaml](install.yaml): DDEV installation file\n- [test.bats](tests/test.bats): test suite to ensure the add-on is working.\n- [Github actions setup](.github/workflows/tests.yml): file to automate checks and tests.\n\n## Getting started\n\nThis add-on assumes the developer has:\n\n- Installed Vitest via their preferred package manager.\n\n1. Install the add-on and restart DDEV\n\n   ```shell\n   ddev add-on get tyler36/ddev-vitest\n   ddev restart\n   ```\n\n## Commands\n\n### `ddev vitest`\n\n`ddev vitest` is a helper command to run Vitest from the host.\nIt accepts all flags accepted by vitest.\nFor example, to see the currently installed version of Vitest:\n\n  ```shell\n  ddev vitest --version\n  ```\n\n\u003e [!NOTE]\n\u003e If you attempt to start Vitest UI via `ddev vitest --ui`, this addon hijacks the command and re-writes it to be compatible with DDEV.\n\n### `ddev vitest-ui`\n\nUse the following command to start the Vitest UI server and launch the site in your default browser:\n\n```shell\nddev vitest-ui -s\n```\n\nIf the server is already started, use `ddev vitest-ui` to launch the site\n\n## Auto-start Vitest UI\n\nUse DDEV's `post-start` hook to automatically start Vitest UI.\n\nThe following snippet starts the UI server and launches the test page.\n\n```yaml\nhooks:\n  post-start:\n    - exec-host: ddev vitest-ui\n```\n\n## Vite\n\nVitest is a great companion to Vite.\nFor more information about using Vite with DDEV,\n\n- [tyler36/ddev-vite](https://github.com/tyler36/ddev-vite): a DDEV addon for Vite.\n- Matthias Andrasch's excellent blog post - [Working with Vite in DDEV - an introduction](https://ddev.com/blog/working-with-vite-in-ddev/).\n\n**Contributed and maintained by `tyler36`**\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftyler36%2Fddev-vitest","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftyler36%2Fddev-vitest","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftyler36%2Fddev-vitest/lists"}