
Grab your gear: The official Sanity swag store
Read Grab your gear: The official Sanity swag storeI understand you're seeing some code in a repository that references webpack configuration customization and @sanity/server, and you're wondering when it will be released or how to install from a specific commit.
First, let me clarify the current state of Sanity Studio's build tooling: Sanity Studio has used Vite (not webpack) since Studio v3 was released in January 2023. The @sanity/server package was part of the older Studio v2 architecture and is no longer actively developed.
However, I want to acknowledge that you're seeing specific code in a repository, and there could be a few scenarios here:
If you're looking at the main Sanity repository:
For customizing the build configuration in modern Sanity Studio, you'll want to work with Vite configuration instead. This is done in your sanity.config.ts (or .js) file:
// sanity.config.ts
import {defineConfig} from 'sanity'
export default defineConfig({
// Your project settings
projectId: 'your-project-id',
dataset: 'production',
// Custom Vite configuration
vite: {
// Your custom Vite configuration here
// This gets merged with Sanity's defaults
}
})According to the Sanity documentation on Vite, custom Vite configuration is automatically merged with Sanity's default configuration using Vite's merge logic.
Regarding installing from a specific commit in a monorepo:
If you really need to install a package from a specific GitHub commit, you can reference it in your package.json:
{
"dependencies": {
"sanity": "sanity-io/sanity#commit-hash"
}
}However, this approach has limitations with monorepos since it will try to install the entire repository, not a specific package within it.
My recommendation: Before trying to install unreleased code, I'd suggest reaching out on the Sanity Slack community or opening a GitHub issue to clarify:
Could you share the specific GitHub URL or commit you're referencing? That would help the community provide more specific guidance on whether this is something you should be using and when it might be officially released. The Sanity team is pretty responsive on Slack and can let you know if there's a timeline for any webpack-related features you might be seeing in the codebase.
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.
Content operations
Content backend


The only platform powering content operations
By Industry


Tecovas strengthens their customer connections
Build and Share

Grab your gear: The official Sanity swag store
Read Grab your gear: The official Sanity swag store