We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug
I tried to disable the asset source for a specific schema following the Manually configure asset sources section in README but it is not working.
Manually configure asset sources
To Reproduce
Steps to reproduce the behavior:
image
movie-image
import { unsplashImageAsset, unsplashAssetSource } from 'sanity-plugin-asset-source-unsplash' export default defineConfig({ // ... plugins: [unsplashImageAsset()], form: { image: { assetSources: (previousAssetSources, { schema }) => { if (schema.name === 'movie-image') { // remove unsplash from movie-image types return previousAssetSources.filter((assetSource) => assetSource !== unsplashAssetSource) } return previousAssetSources }, }, }, })
Expected behavior
movie-image shouldn't have unsplash as in source dropdown
Which versions of Sanity are you using?
@sanity/cli (global) 3.29.1 (latest: 3.44.0) @sanity/astro 3.0.0 (latest: 3.1.3) @sanity/code-input 4.1.4 (up to date) @sanity/vision 3.41.1 (latest: 3.44.0) sanity 3.41.1 (latest: 3.44.0)
What operating system are you using?
Which versions of Node.js / npm are you running?
10.5.0 v20.11.0
Additional context
When I console log schema.name it returns undefined
schema.name
undefined
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Describe the bug
I tried to disable the asset source for a specific schema following the
Manually configure asset sources
section in README but it is not working.To Reproduce
Steps to reproduce the behavior:
image
calledmovie-image
Expected behavior
movie-image
shouldn't have unsplash as in source dropdownWhich versions of Sanity are you using?
@sanity/cli (global) 3.29.1 (latest: 3.44.0)
@sanity/astro 3.0.0 (latest: 3.1.3)
@sanity/code-input 4.1.4 (up to date)
@sanity/vision 3.41.1 (latest: 3.44.0)
sanity 3.41.1 (latest: 3.44.0)
What operating system are you using?
Which versions of Node.js / npm are you running?
10.5.0
v20.11.0
Additional context
When I console log
schema.name
it returnsundefined
The text was updated successfully, but these errors were encountered: