Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 27 additions & 2 deletions apps/docs-app/docs/features/testing/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,33 @@ Vitest supports many features:
- In-source testing.
- And more ...

You can also [add Vitest](/docs/features/testing/vitest) to your existing project.

## Angular support for Vitest

In Angular v21, stable support for Vitest directly through the Angular CLI was introduced for new Angular projects. While both Analog and Angular support running tests with Vitest, there are some similarities and key differences.

The table below shows the features available across both choices.

| Vitest | Analog | Angular |
| -------------------- | --------- | ------------ |
| Angular Versions | v17+ | v21+ |
| Support | Community | Angular Team |
| Builders | ✅ | ✅ |
| Schematics | ✅ | ✅ |
| Migrations | ✅ | ✅ |
| Fully Configurable | ✅ | ⚠️ |
| Vitest CLI | ✅ | ❌ |
| Vitest Workpsaces | ✅ | ❌ |
| Custom Environments | ✅ | ❌ |
| Custom Providers | ✅ | ❌ |
| IDE extensions | ✅ | ❌ |
| Buildable Libs | ✅ | ❌ |
| Module Mocking/Graph | ✅ | ❌ |
| Plugins/Types | ✅ | ❌ |

The table above is not to compare the two solutions, but to provide the information on what features are supported by each implementation. Choose the solution that best fits your needs and priorities.

## Running Unit Tests

To run unit tests, use the `test` command:
Expand Down Expand Up @@ -48,8 +75,6 @@ pnpm run test
</TabItem>
</Tabs>

You can also [add Vitest](/docs/features/testing/vitest) to your existing project.

## IDE Support

Tests can also be run directly from your IDE using the Vitest [IDE integrations](https://vitest.dev/guide/ide) for VS Code or JetBrains IDEs.
Expand Down
2 changes: 2 additions & 0 deletions apps/docs-app/docs/guides/compatibility.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Below is a reference table that matches compatible versions of Angular with the

| Angular Version | Analog Version | Vite Version |
| --------------- | -------------- | ------------ |
| ^20.0.0 | **latest** | ^7.0.0 |
| ^19.1.0 | **latest** | ^6.0.0 |
| ^18.0.0 | **latest** | ^5.0.0 |
| ^17.0.0 | **latest** | ^5.0.0 |
Expand All @@ -24,6 +25,7 @@ The table shows the minimum version of Nx, the supported Angular version, and th

| Nx Version _(min)_ | Angular Version | Analog Version | Vite Version |
| ------------------ | --------------- | -------------- | ------------ |
| 21.x.x | ^20.x.x | **latest** | ^7.0.0 |
| 20.4.0 | ^19.1.0 | **latest** | ^6.0.0 |
| 18.0.0 | ^17.0.0 | **latest** | ^5.0.0 |
| 17.0.0 | ^17.0.0 | **latest** | ^5.0.0 |
Expand Down