Skip to content

Commit

Permalink
feat: adds support for Create-Studio integration (#7635)
Browse files Browse the repository at this point in the history
Co-authored-by: Robin Pyon <robin.pyon@gmail.com>
  • Loading branch information
snorrees and robinpyon authored Oct 25, 2024
1 parent 1ebedd2 commit 12cb46b
Show file tree
Hide file tree
Showing 68 changed files with 2,641 additions and 37 deletions.
3 changes: 3 additions & 0 deletions dev/test-create-integration-studio/.depcheckignore.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"ignore": ["styled-components", "react", "react-dom", "sanity"]
}
1 change: 1 addition & 0 deletions dev/test-create-integration-studio/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/dist
22 changes: 22 additions & 0 deletions dev/test-create-integration-studio/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"name": "test-create-integration-studio",
"version": "3.61.0",
"private": true,
"license": "MIT",
"author": "Sanity.io <hello@sanity.io>",
"scripts": {
"build": "../.bin/sanity build",
"clean": "rimraf .sanity dist",
"deploy": "npx sanity deploy",
"dev": "../.bin/sanity dev",
"lint": "eslint .",
"start": "../.bin/sanity start"
},
"dependencies": {
"@sanity/code-input": "^4.1.4",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"sanity": "workspace:*",
"styled-components": "^6.1.0"
}
}
11 changes: 11 additions & 0 deletions dev/test-create-integration-studio/sanity.cli.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import {defineCliConfig} from 'sanity/cli'

export default defineCliConfig({
api: {
projectId: 'ppsg7ml5',
dataset: 'test',
},

studioHost: 'create-integration-test',
autoUpdates: false,
})
22 changes: 22 additions & 0 deletions dev/test-create-integration-studio/sanity.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// eslint-disable-next-line import/no-extraneous-dependencies
import {codeInput} from '@sanity/code-input'
import {defineConfig} from 'sanity'
import {structureTool} from 'sanity/structure'

import {schemaTypes} from './schema'

export default defineConfig({
plugins: [structureTool(), codeInput()],
title: 'Strict',
name: 'default',
projectId: 'ppsg7ml5',
dataset: 'test',
schema: {types: schemaTypes},

beta: {
create: {
startInCreateEnabled: true,
fallbackStudioOrigin: 'create-integration-test.sanity.studio',
},
},
})
Loading

0 comments on commit 12cb46b

Please sign in to comment.