Multiple versions of @sanity/generate-help-url from block-content-to-hyperscript

25 replies
Last updated: Jan 27, 2026
Hey everyone, I am having an issue after updating a bit of an older project. I am getting a multiple versions issue for @sanity/generate-help-url. The old version is being called from ./~/@sanity/block-content-to-hyperscript/~/@sanity/generate-help-url, however, I am not using block-content-to-hyperscript anywhere. Wondering if that needs to be updated in the core Sanity package?
AI Update

This is a dependency conflict issue that's actually not a problem with your code, but rather with an outdated transitive dependency. Here's what's happening:

The @sanity/block-content-to-hyperscript package is deprecated and has been replaced by modern alternatives. Even though you're not directly using it in your project, some older Sanity package might still have it as a dependency, which is causing the version conflict with @sanity/generate-help-url.

Solution

The best approach is to migrate away from the deprecated packages. According to the official Sanity documentation, here are the modern replacements:

For rendering Portable Text:

  1. For HTML: Use @portabletext/to-html instead of @sanity/block-content-to-html or @sanity/block-content-to-hyperscript

  2. For React: Use @portabletext/react instead of @sanity/block-content-to-react

  3. For other frameworks: There are modern packages for Vue, Svelte, React Native, and Astro

Immediate workarounds:

If you can't migrate immediately, try these:

  1. Use npm resolutions (in package.json):
{
  "resolutions": {
    "@sanity/generate-help-url": "^3.0.0"
  }
}
  1. Use yarn resolutions or npm overrides to force a single version

  2. Clear your lock file and reinstall:

rm -rf node_modules package-lock.json
npm install

Long-term fix:

Check which Sanity packages you're using and update them to their latest versions. The core Sanity packages have been updated to remove dependencies on these deprecated packages. Run:

npm outdated

Then update your Sanity packages:

npm update @sanity/client sanity

The block-content-to-hyperscript package is no longer maintained by Sanity, so this isn't something that will be "fixed in the core Sanity package" - it's been replaced by the modern Portable Text tooling mentioned above.

Show original thread
25 replies

Sanity – Build the way you think, not the way your CMS thinks

Sanity is the developer-first content operating system that gives you complete control. Schema-as-code, GROQ queries, and real-time APIs mean no more workarounds or waiting for deployments. Free to start, scale as you grow.

Was this answer helpful?