Files
Jiwon ChoiandGitHub 18b18e228a fix(agents-md): use require.resolve() to get the installed next version (#89166)
### Why?

When the package.json has Next.js version with a tag instead of a
specific version, e.g., `"next": "canary"`, it received an error:

```
Failed to pull docs: Could not find documentation for Next.js vcanary. This version may not exist on GitHub yet.
```

### How?

Modified logic to get version to use `require.resolve()`.

#### Before


https://github.com/user-attachments/assets/487d0404-ad81-4c5c-a341-cab9a0e03020

#### After


https://github.com/user-attachments/assets/4153873f-681f-4c46-8ee0-ee7913749b7b
2026-02-14 20:36:47 +00:00
..