sanity icon indicating copy to clipboard operation
sanity copied to clipboard

Export types ScheduledPublishingPluginOptions and BetaFeatures

Open saiichihashimoto opened this issue 4 months ago • 0 comments

Describe the bug

The types ScheduledPublishingPluginOptions and BetaFeatures aren't exported, which makes it impossible to reexport the defineConfig.

To Reproduce

Steps to reproduce the behavior:

I'm working on sanity-typed, so all of these things are within that repo

  1. Update sanity to 3.61.0 (or anything past 3.38.0).
  2. npm install
  3. npm build, watch it break.
  4. (If I go into packages/types/node_modules/sanity/lib/index.d.ts and change declare interface ScheduledPublishingPluginOptions to export interface ScheduledPublishingPluginOptions, everything works)

Expected behavior

For builds re-exporting defineConfig not to break

Screenshots

@sanity-typed/types:build: src/internal.ts(1324,14): error TS4023: Exported variable 'defineConfig' has or is using name 'ScheduledPublishingPluginOptions' from external module "/Users/shayan/Workspace/sanity-typed/node_modules/sanity/lib/index" but cannot be named.
@sanity-typed/types:build: src/internal.ts(1324,14): error TS4023: Exported variable 'defineConfig' has or is using name 'BetaFeatures' from external module "/Users/shayan/Workspace/sanity-typed/node_modules/sanity/lib/index" but cannot be named.
image

saiichihashimoto avatar Oct 19 '24 20:10 saiichihashimoto