Skip to content

Commit

Permalink
Add "path aliases in config files" to known issues (closes #558)
Browse files Browse the repository at this point in the history
  • Loading branch information
webpro committed Mar 20, 2024
1 parent d33beab commit fb92db7
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions packages/docs/src/content/docs/reference/known-issues.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,24 @@ TypeError: Reflect.metadata is not a function

[GitHub Issue #355][7]

## Path aliases in config files

```
Analyzing workspace ....
Error loading .../cypress.config.ts
Reason: Cannot find module '@alias/name'
Require stack:
- .../cypress.config.ts
```

Some tools (such as Cypress and Jest) support using TypeScript path aliases in
the configuration file. Unfortunately jiti does not seem to support this.

Potential workarounds:

- Rewrite the import the configuration to a relative import.
- Use Bun: `bunx --bun knip` (Bun will execute the scripts instead of jiti)

[1]: https://github.com/unjs/jiti
[2]: ./configuration.md#plugins
[3]: https://github.com/unjs/jiti/issues/72
Expand Down

0 comments on commit fb92db7

Please sign in to comment.