Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
194 commits
Select commit Hold shift + click to select a range
27a3c09
first commit with field level experiments
jjburbridge Nov 13, 2024
cde71ee
chore(deps): add .github/renovate.json
renovate[bot] Nov 13, 2024
25ab472
updated readme, github links and bug fix for no values
jjburbridge Nov 13, 2024
f28093b
updated typos and removed setting _key as it would not work wiht init…
jjburbridge Nov 15, 2024
0fdba32
updated readme to remove additonal ,
jjburbridge Nov 18, 2024
aefd877
added realease workflow
jjburbridge Nov 18, 2024
369b7be
testing releases
jjburbridge Nov 18, 2024
10a2bea
testing releases
jjburbridge Nov 18, 2024
dd060b3
updated release branches
jjburbridge Nov 18, 2024
3eabb7f
added required dependency
jjburbridge Nov 18, 2024
2f1b67f
Merge pull request #1 from sanity-io/renovate/configure
jjburbridge Nov 19, 2024
075b6a6
chore: updated releases based on pluginkit
jjburbridge Nov 20, 2024
810e913
fix: add field action to show hide extra experiment data
jjburbridge Nov 20, 2024
f4cdf44
fix: add field action to show hide extra experiment data
jjburbridge Nov 20, 2024
d2613a3
fix: on removal of experiment clear additional fields
jjburbridge Nov 20, 2024
5603ca8
Merge pull request #4 from sanity-io/hide-exp
jjburbridge Nov 21, 2024
54bf39b
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personalisa…
jjburbridge Nov 21, 2024
881e19f
feat: updated name of package
jjburbridge Nov 21, 2024
970419f
Merge pull request #2 from sanity-io/releases
jjburbridge Nov 22, 2024
0230af6
chore: fix semantic-release
jjburbridge Nov 22, 2024
119280a
Merge pull request #5 from sanity-io/fix-semantic-release
jjburbridge Nov 22, 2024
aab18a4
chore: set overriodes to resolutions
jjburbridge Nov 22, 2024
cc296d0
chore: allow release on this test branch
jjburbridge Nov 22, 2024
c5f4389
chore: remove dry run
jjburbridge Nov 22, 2024
1d8989f
Merge pull request #6 from sanity-io/fix-semantic-release
jjburbridge Nov 22, 2024
f27459e
chore: updated release workflow
jjburbridge Nov 25, 2024
5e440c1
Merge pull request #7 from sanity-io/releases
jjburbridge Nov 25, 2024
74f9a2c
chore(release): 1.0.0 [skip ci]
semantic-release-bot Nov 25, 2024
a991386
fix: update relase workflow
jjburbridge Nov 25, 2024
7ff2c0b
Merge pull request #8 from sanity-io/public-release
jjburbridge Nov 25, 2024
22c8d98
chore(release): 1.0.1 [skip ci]
semantic-release-bot Nov 25, 2024
95fbaae
chore: set package to public release
jjburbridge Nov 26, 2024
0187bab
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personalisa…
jjburbridge Nov 26, 2024
c6f6934
Merge pull request #9 from sanity-io/public-release
jjburbridge Nov 26, 2024
847a8a1
fix: updated name of package in readme
jjburbridge Nov 26, 2024
b76c0e5
Merge pull request #11 from sanity-io/public-release
jjburbridge Nov 26, 2024
5b3e23d
chore(release): 1.0.2 [skip ci]
semantic-release-bot Nov 26, 2024
345be57
chore(deps): update non-major
renovate[bot] Nov 26, 2024
b5dc4e9
Merge pull request #10 from sanity-io/renovate/non-major
jjburbridge Nov 26, 2024
d0eb0cc
fix: updated plugin name to match scoped package
jjburbridge Nov 26, 2024
1286d76
Merge pull request #12 from sanity-io/plugin-name
jjburbridge Nov 26, 2024
f1baf6b
chore(release): 1.0.3 [skip ci]
semantic-release-bot Nov 26, 2024
d28d2cc
feat: added growthbook flied experiments as a plugin
jjburbridge Nov 28, 2024
936068d
feat: allow canary branch to make releases
jjburbridge Nov 28, 2024
db58178
Merge pull request #14 from sanity-io/canary-releases
jjburbridge Nov 28, 2024
bef137f
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personalisa…
jjburbridge Nov 28, 2024
880eefd
chore: new workflow for doing pre-releases of any branch
jjburbridge Nov 28, 2024
9b70f1b
Merge pull request #15 from sanity-io/pre-release-workflow
jjburbridge Nov 28, 2024
48e09ae
chore: update pre-release cmd
jjburbridge Nov 28, 2024
733c6de
chore: fix typo
jjburbridge Nov 28, 2024
a978f4a
chore: escapre braces
jjburbridge Nov 28, 2024
4b11ca0
chore: escape the quotes
jjburbridge Nov 29, 2024
7f64e34
chore: fix the json for pre-release
jjburbridge Nov 29, 2024
365c493
chore: update comments
jjburbridge Nov 29, 2024
fd075dd
Merge pull request #16 from sanity-io/pre-release-workflow
jjburbridge Nov 29, 2024
37a66df
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personalisa…
jjburbridge Nov 29, 2024
8d059d9
chore(release): 1.1.0-growthbook.1 [skip ci]
semantic-release-bot Nov 29, 2024
48a08bd
chore: updating readme to include more details
jjburbridge Nov 29, 2024
80d3905
chore: add more context in readme
jjburbridge Dec 4, 2024
b61cdce
fix: use onchagne from props rather than document operation for patch
jjburbridge Dec 9, 2024
dba609b
Merge pull request #19 from sanity-io/sa-110
jjburbridge Dec 9, 2024
6525aa1
chore(release): 1.1.0 [skip ci]
semantic-release-bot Dec 9, 2024
bca3b37
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personalisa…
jjburbridge Dec 9, 2024
0e39192
chore: updated icon for adding experiment
jjburbridge Dec 10, 2024
827cf0f
chore: added gif show use of plugin
jjburbridge Dec 10, 2024
fcdb589
chore: included example of async function getting/mapping experiments…
jjburbridge Dec 10, 2024
b12953a
Merge pull request #20 from sanity-io/update-readme
jjburbridge Dec 17, 2024
e81af6e
chore(deps): update non-major
renovate[bot] Dec 17, 2024
1223115
Merge pull request #17 from sanity-io/renovate/non-major
jjburbridge Dec 18, 2024
4933440
chore(deps): lock file maintenance
renovate[bot] Dec 18, 2024
57c4cb4
Merge pull request #18 from sanity-io/renovate/lock-file-maintenance
jjburbridge Dec 18, 2024
eb40e0b
fix: get experiments from feature flags for growthbook and store valu…
jjburbridge Dec 19, 2024
e0cc75f
chore(release): 1.2.0-growthbook.1 [skip ci]
semantic-release-bot Dec 19, 2024
51a3a59
feat: added boolena conversion check
jjburbridge Dec 24, 2024
5d86b83
Merge branch 'growthbook' of github.com:sanity-io/sanity-plugin-perso…
jjburbridge Dec 24, 2024
57d3d9a
fix: remove unneeded comments
jjburbridge Jan 2, 2025
29e3e4c
Merge pull request #21 from sanity-io/release
jjburbridge Jan 2, 2025
8feac83
chore(release): 1.1.1 [skip ci]
semantic-release-bot Jan 2, 2025
3fcacb9
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personalisa…
jjburbridge Jan 9, 2025
8a2f9cb
chore: typo fix
jjburbridge Jan 10, 2025
c479c65
feat: updated list preview to reflect experiment variants
jjburbridge Jan 13, 2025
3389168
refactor: used helper function for checking if image
jjburbridge Jan 16, 2025
7a6065f
Merge pull request #22 from sanity-io/array-preview
jjburbridge Jan 17, 2025
7a7e822
WIP - moving fields around
jjburbridge Jan 31, 2025
49e07cb
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personalisa…
jjburbridge Jan 31, 2025
a0eb18d
fix: only show secret input when finished loading
jjburbridge Feb 5, 2025
03fdf16
added todo comments
jjburbridge Feb 6, 2025
3cfcae3
refactor: naming
jjburbridge Feb 6, 2025
f7dc993
docs: added update to readme to show old name
jjburbridge Feb 6, 2025
79d0b02
docs: updated repo link
jjburbridge Feb 7, 2025
fa3658c
Merge pull request #23 from sanity-io/rename
jjburbridge Feb 7, 2025
761e75e
chore(deps): bump vite from 5.4.11 to 5.4.14
dependabot[bot] Feb 7, 2025
4393092
Merge pull request #24 from sanity-io/dependabot/npm_and_yarn/vite-5.…
jjburbridge Feb 7, 2025
8f9e9d5
chore(deps): update non-major
renovate[bot] Feb 7, 2025
17b15ca
Merge pull request #25 from sanity-io/renovate/non-major
jjburbridge Feb 7, 2025
1554c0d
chore(release): 2.0.0 [skip ci]
semantic-release-bot Feb 7, 2025
ba4ad55
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personaliza…
jjburbridge Feb 10, 2025
f42e75c
feat: allow overiding of experiment and variant field names
jjburbridge Feb 10, 2025
6372881
chore(release): 2.1.0-field-names.1 [skip ci]
semantic-release-bot Feb 10, 2025
573c2f3
docs: updated readme to include experiment and variant name overwrites
jjburbridge Feb 10, 2025
23eecb5
Merge branch 'field-names' of github.com:sanity-io/sanity-plugin-pers…
jjburbridge Feb 10, 2025
d2ab76a
docs: clearer deffinition of fields created
jjburbridge Feb 10, 2025
1ad4391
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personaliza…
jjburbridge Feb 11, 2025
ef300fb
feat: new config option, updated experiment fetching
jjburbridge Feb 14, 2025
add12bd
docs: added readme for growthbook
jjburbridge Feb 14, 2025
53a502c
docs: added link to growthbook readme on main readme
jjburbridge Feb 14, 2025
befc2fa
docs: missing comma
jjburbridge Feb 14, 2025
f4d4067
chore(release): 2.1.0-growthbook.1 [skip ci]
semantic-release-bot Feb 14, 2025
c1ff90a
feat: added ability to copy default to a variant
jjburbridge Feb 17, 2025
09a0939
chore: removed dead code
jjburbridge Feb 17, 2025
7a54a3b
wip adding launch darkly as an export
jjburbridge Feb 21, 2025
d501e7b
Merge pull request #27 from sanity-io/sa-123-copy-default
jjburbridge Feb 21, 2025
25d8d99
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personaliza…
jjburbridge Feb 21, 2025
002107a
chore: reset changelog and package version to base
jjburbridge Feb 21, 2025
238609f
Merge pull request #26 from sanity-io/field-names
jjburbridge Feb 21, 2025
57afd2b
chore(release): 2.1.0 [skip ci]
semantic-release-bot Feb 21, 2025
05b95db
feat: use sanity secrets, ability to filter and paginate request to LD
jjburbridge Mar 19, 2025
52bf40c
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personaliza…
jjburbridge Mar 19, 2025
87430f0
chore(release): 2.2.0-launch-darkly.1 [skip ci]
semantic-release-bot Mar 19, 2025
6ed4175
fix: use value for variant label if no label
jjburbridge Mar 20, 2025
42d3db2
docs: added readme for LD export
jjburbridge Mar 20, 2025
1b8c5f2
Merge branch 'launch-darkly' of github.com:sanity-io/sanity-plugin-pe…
jjburbridge Mar 20, 2025
522e2eb
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personaliza…
jjburbridge Mar 21, 2025
24f018e
fix: resolved issue with too many re renders on experiments
jjburbridge Mar 21, 2025
a6e209b
chore(release): 2.2.0-growthbook.1 [skip ci]
semantic-release-bot Mar 21, 2025
9302f08
feat: added message to warn there are no defeined experiments
jjburbridge Mar 26, 2025
177c96e
Merge pull request #29 from sanity-io/sa-209-empty-message
jjburbridge Mar 26, 2025
8c87729
chore(release): 2.2.0 [skip ci]
semantic-release-bot Mar 26, 2025
d72a8c3
chore: updated peer deps to accept react 19
jjburbridge Apr 2, 2025
b9b841d
Merge branch 'main' into launch-darkly
jjburbridge Apr 2, 2025
9eaddd5
chore(release): 2.3.0-launch-darkly.1 [skip ci]
semantic-release-bot Apr 2, 2025
52ab544
fix: ensure that values are not duplicated
jjburbridge Apr 14, 2025
bcc1034
feat: made growthbook its own subpath export
jjburbridge Apr 15, 2025
c27316f
refactor: renamed export as now on subpath
jjburbridge Apr 15, 2025
25d7745
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personaliza…
jjburbridge Apr 15, 2025
4d9b4f1
fix: updated base url to use corect api domain
jjburbridge Apr 15, 2025
c946ff6
docs: updated docs to includ optional tags config
jjburbridge Apr 15, 2025
b1765e7
docs: updated name of export
jjburbridge Apr 15, 2025
97fcb9c
refactor: make code more reusable
jjburbridge Apr 15, 2025
6ade3da
chore(release): 2.3.0-growthbook.1 [skip ci]
semantic-release-bot Apr 15, 2025
021e96c
feat: movec LaunchDarkly export to own subpath and refactored
jjburbridge Apr 23, 2025
bbe64aa
fix: updated so all values from LD stored as strings
jjburbridge Apr 23, 2025
4af1a61
chore(release): 2.3.0-launch-darkly.2 [skip ci]
semantic-release-bot Apr 23, 2025
d214f9b
Merge branch 'launch-darkly' of github.com:sanity-io/sanity-plugin-pe…
jjburbridge Apr 25, 2025
75c9a78
fix: works with content releases and removes variants if experiment c…
jjburbridge Apr 25, 2025
1592141
Merge pull request #30 from sanity-io/releases-update
jjburbridge Apr 25, 2025
11cf8b1
chore(release): 2.2.1 [skip ci]
semantic-release-bot Apr 25, 2025
a423b46
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personaliza…
jjburbridge Apr 30, 2025
1f2c967
chore(release): 2.3.0-growthbook.2 [skip ci]
semantic-release-bot May 6, 2025
5123fcf
chore: rename config type name and removed pre release
jjburbridge May 6, 2025
d5d1aa8
Merge branch 'growthbook' of github.com:sanity-io/sanity-plugin-perso…
jjburbridge May 6, 2025
f0e3c0e
Merge pull request #13 from sanity-io/growthbook
jjburbridge May 6, 2025
5d874b8
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personaliza…
jjburbridge May 6, 2025
279b110
chore(release): 2.3.0 [skip ci]
semantic-release-bot May 6, 2025
0cb34f3
feat: increase flatten depth (#31)
ChrisLaRocque May 16, 2025
1f3cdbd
chore(release): 2.4.0 [skip ci]
semantic-release-bot May 16, 2025
0191341
fix: improved preview when used in array
jjburbridge Jun 25, 2025
e1402db
fix: added media to preview
jjburbridge Jun 25, 2025
cf3879a
docs: updated readme to show working in arrays
jjburbridge Jun 25, 2025
d8beda3
Fix: improved preview in arraays
jjburbridge Jul 1, 2025
8b8e6a1
fix(deps): allow studio v4 in peer dep ranges (#34)
RitaDias Jul 10, 2025
3b4406c
chore(release): 2.4.1 [skip ci]
semantic-release-bot Jul 10, 2025
f43b41d
Update README.md
RitaDias Jul 11, 2025
cc9e84e
Merge pull request #35 from sanity-io/RitaDias-patch-1
RitaDias Jul 11, 2025
6313b7b
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personaliza…
jjburbridge Jul 21, 2025
32ba26c
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personaliza…
jjburbridge Jul 21, 2025
2cc90b1
chore: updates deps
jjburbridge Jul 21, 2025
6c1a1fa
chore(release): 2.5.0-launch-darkly.1 [skip ci]
semantic-release-bot Jul 21, 2025
cd32cc7
docs: added information on using the plugin to do split testing
jjburbridge Aug 14, 2025
37e4f9c
Merge pull request #36 from sanity-io/docs/split-testing
jjburbridge Aug 14, 2025
14039d3
chore(deps): update non-major
renovate[bot] Aug 14, 2025
85ee8bd
Merge pull request #33 from sanity-io/renovate/non-major
jjburbridge Aug 14, 2025
a62e6fa
fix: when used in modal auto set to active
jjburbridge Aug 15, 2025
0be717b
fix: copy default works in modals
jjburbridge Aug 15, 2025
52d9108
Merge pull request #37 from sanity-io/improved-modal
jjburbridge Aug 15, 2025
dd21d46
chore(release): 2.4.2 [skip ci]
semantic-release-bot Aug 15, 2025
34b7d99
fix(deps): make peer dependencies include sanity 5.x
pedrobonamin Dec 18, 2025
32f7dce
Merge pull request #39 from sanity-io/fix-sanity-v5
pedrobonamin Dec 18, 2025
e308ee5
chore(release): 2.4.3 [skip ci]
semantic-release-bot Dec 18, 2025
673513c
Merge branch 'main' of github.com:sanity-io/sanity-plugin-personaliza…
jjburbridge Jan 19, 2026
b463d37
refactor: updating for merge
jjburbridge Jan 19, 2026
847b02d
Merge pull request #28 from sanity-io/launch-darkly
jjburbridge Jan 19, 2026
60e2477
chore(release): 2.5.0 [skip ci]
semantic-release-bot Jan 19, 2026
fbc8826
Rewrite and expand README documentation
netmagik Feb 9, 2026
4d1875d
style, update userId approach and slug-based path rewrite
netmagik Feb 20, 2026
d6d11f3
add note about getting user id with auth integration
netmagik Feb 23, 2026
9301f25
Merge pull request #54 from sanity-io/feat/update-readme
netmagik Feb 25, 2026
5fb4c2f
Add 'plugins/@sanity/personalization-plugin/' from commit '9301f2510a…
cursoragent Jun 12, 2026
b37762c
chore(@sanity/personalization-plugin): remove files that will be rege…
cursoragent Jun 12, 2026
c375a66
chore(personalization-plugin): scaffold monorepo config and restore d…
cursoragent Jun 12, 2026
7e24a12
refactor(personalization-plugin): adapt source to monorepo lint rules
cursoragent Jun 12, 2026
5959772
feat(test-studio): add personalization plugin example
cursoragent Jun 12, 2026
467facf
docs(personalization-plugin): add major changeset and root README entry
cursoragent Jun 12, 2026
0c663d0
Merge remote-tracking branch 'origin/main' into cursor/migrate-person…
cursoragent Jun 12, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .changeset/personalization-plugin-transfer.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
'@sanity/personalization-plugin': major
---

Port @sanity/personalization-plugin to the Sanity plugins monorepo

This major release includes several breaking changes as part of the migration to the monorepo:

- **React Compiler enabled**: The package is now built with React Compiler targeting React 19
- **ESM-only**: CommonJS support has been removed. The package now ships only ESM
- **React 19.2+ required**: Minimum React version is now 19.2 (previously ^18 || ^19)
- **react-dom 19.2+ required**: `react-dom` is now a required peer dependency
- **Sanity Studio v5+ required**: Minimum Sanity version is now v5 (Sanity v3 and v4 are no longer supported)
- **Node.js 20.19+ required**: Minimum Node.js version is now 20.19 (previously >=18)
- **Sanity v2 compatibility shim removed**: The `@sanity/incompatible-plugin` dependency, `sanity.json`, and `v2-incompatible.js` are no longer shipped
10 changes: 10 additions & 0 deletions .oxlintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,16 @@
"restrict-template-expressions": "off"
}
},
{
"files": ["plugins/@sanity/personalization-plugin/src/**/*.{ts,tsx}"],
"rules": {
"no-unsafe-type-assertion": "off",
"restrict-template-expressions": "off",
"no-base-to-string": "off",
"no-await-in-loop": "off",
"react-hooks-js/set-state-in-effect": "off"
}
},
{
"files": ["plugins/sanity-naive-html-serializer/test/**/*.ts"],
"rules": {
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ Sessions can be compared in the DevTools UI to diff bundle changes between build
| [`@sanity/document-internationalization`](./plugins/@sanity/document-internationalization) | Document-level translations linked by a shared reference |
| [`@sanity/language-filter`](./plugins/@sanity/language-filter) | Filter localized fields by language |
| [`@sanity/orderable-document-list`](./plugins/@sanity/orderable-document-list) | Drag-and-drop document ordering without leaving the editing surface |
| [`@sanity/personalization-plugin`](./plugins/@sanity/personalization-plugin) | Field-level personalization and A/B testing experiments |
| [`@sanity/presets`](./plugins/@sanity/presets) | Experimental preset patterns for Sanity Studio |
| [`@sanity/rich-date-input`](./plugins/@sanity/rich-date-input) | Timezone-aware datetime input for Sanity Studio |
| [`@sanity/studio-secrets`](./plugins/@sanity/studio-secrets) | Manage Studio secrets at runtime |
Expand Down
1 change: 1 addition & 0 deletions dev/test-studio/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
"@sanity/icons": "^3.7.4",
"@sanity/language-filter": "workspace:*",
"@sanity/orderable-document-list": "workspace:*",
"@sanity/personalization-plugin": "workspace:*",
"@sanity/presets": "workspace:*",
"@sanity/rich-date-input": "workspace:*",
"@sanity/sfcc": "workspace:*",
Expand Down
2 changes: 2 additions & 0 deletions dev/test-studio/sanity.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ import {
orderableDocumentListExample,
orderableDocumentListExampleStructure,
} from '#orderable-document-list'
import {personalizationExample} from '#personalization'
import {presetsWorkspace} from '#presets'
import {richDateInputExample} from '#rich-date-input'
import {sanityNaiveHtmlSerializerExample} from '#sanity-naive-html-serializer'
Expand Down Expand Up @@ -104,6 +105,7 @@ export default defineConfig([
assistExample(),
googleTranslateExample(),
// add new plugins here
personalizationExample(),
orderableDocumentListExample(),
latexInputExample(),
debugLiveSyncTagsExample(),
Expand Down
51 changes: 51 additions & 0 deletions dev/test-studio/src/personalization/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
import {fieldLevelExperiments} from '@sanity/personalization-plugin'
import {defineField, definePlugin, defineType} from 'sanity'

const experiments = [
{
id: 'homepage-headline',
label: 'Homepage Headline Test',
variants: [
{id: 'control', label: 'Control'},
{id: 'emotional', label: 'Emotional Appeal'},
],
},
{
id: 'signup-cta',
label: 'Signup CTA Test',
variants: [
{id: 'control', label: 'Control'},
{id: 'urgent', label: 'Urgency Messaging'},
{id: 'benefit', label: 'Benefit Focused'},
],
},
]

const personalizationTest = defineType({
type: 'document',
name: 'personalizationTest',
title: 'Personalization',
fields: [
defineField({type: 'string', name: 'title', title: 'Title'}),
defineField({
type: 'experimentString',
name: 'headline',
title: 'Headline (A/B testable)',
}),
defineField({
type: 'experimentText',
name: 'description',
title: 'Description (A/B testable)',
}),
],
})

export const personalizationExample = definePlugin(() => ({
schema: {types: [personalizationTest]},
plugins: [
fieldLevelExperiments({
fields: ['string', 'text'],
experiments,
}),
],
}))
5 changes: 5 additions & 0 deletions knip.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,11 @@
],
},
// add new plugin workspaces here
"plugins/@sanity/personalization-plugin": {
"entry": ["package.config.ts"],
"project": ["src/**/*.{ts,tsx}"],
},

"plugins/sanity-plugin-documents-pane": {
"entry": ["package.config.ts"],
"project": ["src/**/*.{ts,tsx}"],
Expand Down
137 changes: 137 additions & 0 deletions plugins/@sanity/personalization-plugin/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,137 @@
# @sanity/personalization-plugin

## [2.5.0](https://github.com/sanity-io/sanity-plugin-personalization/compare/v2.4.3...v2.5.0) (2026-01-19)

### Features

- movec LaunchDarkly export to own subpath and refactored ([021e96c](https://github.com/sanity-io/sanity-plugin-personalization/commit/021e96c4e5c5bfa7d070880aa84cb88efff565cf))
- use sanity secrets, ability to filter and paginate request to LD ([05b95db](https://github.com/sanity-io/sanity-plugin-personalization/commit/05b95db752a5510ea03344470b3043427b0dc7fc))

### Bug Fixes

- updated so all values from LD stored as strings ([bbe64aa](https://github.com/sanity-io/sanity-plugin-personalization/commit/bbe64aacc4da7796b82f527efe38dbd63ab53fda))
- use value for variant label if no label ([6ed4175](https://github.com/sanity-io/sanity-plugin-personalization/commit/6ed417505105a7a5b9049fac273612019dfe123f))

## [2.4.3](https://github.com/sanity-io/sanity-plugin-personalization/compare/v2.4.2...v2.4.3) (2025-12-18)

### Bug Fixes

- **deps:** make peer dependencies include sanity 5.x ([34b7d99](https://github.com/sanity-io/sanity-plugin-personalization/commit/34b7d998eaf2efd24c1b5b91c5c8117b47f8f3cd))

## [2.4.2](https://github.com/sanity-io/sanity-plugin-personalization/compare/v2.4.1...v2.4.2) (2025-08-15)

### Bug Fixes

- copy default works in modals ([0be717b](https://github.com/sanity-io/sanity-plugin-personalization/commit/0be717b83c6fc9fd8fb355813f3c8c88fe99955c))
- when used in modal auto set to active ([a62e6fa](https://github.com/sanity-io/sanity-plugin-personalization/commit/a62e6fae5608ea14ecbfbaae5df2a93f86d09ee7))

## [2.4.1](https://github.com/sanity-io/sanity-plugin-personalization/compare/v2.4.0...v2.4.1) (2025-07-10)

### Bug Fixes

- added media to preview ([e1402db](https://github.com/sanity-io/sanity-plugin-personalization/commit/e1402dbd8eb3efb3455557678ca28b962f3efa24))
- **deps:** allow studio v4 in peer dep ranges ([#34](https://github.com/sanity-io/sanity-plugin-personalization/issues/34)) ([8b8e6a1](https://github.com/sanity-io/sanity-plugin-personalization/commit/8b8e6a1d8de07609aee134a89f40fc8ccf207a16))
- improved preview in arraays ([d8beda3](https://github.com/sanity-io/sanity-plugin-personalization/commit/d8beda3f9fe84c8d68fa6ed45eea60503ad931e3))
- improved preview when used in array ([0191341](https://github.com/sanity-io/sanity-plugin-personalization/commit/0191341e7b24a863189fa0330b16871102b72e63))

## [2.4.0](https://github.com/sanity-io/sanity-plugin-personalization/compare/v2.3.0...v2.4.0) (2025-05-16)

### Features

- increase flatten depth ([#31](https://github.com/sanity-io/sanity-plugin-personalization/issues/31)) ([0cb34f3](https://github.com/sanity-io/sanity-plugin-personalization/commit/0cb34f30062da6e9f792a39534ff8a5b2e7fb007))

## [2.3.0](https://github.com/sanity-io/sanity-plugin-personalization/compare/v2.2.1...v2.3.0) (2025-05-06)

### Features

- added boolena conversion check ([51a3a59](https://github.com/sanity-io/sanity-plugin-personalization/commit/51a3a59199992269dfe6dcf8f054f0f278bb4d7c))
- added growthbook flied experiments as a plugin ([d28d2cc](https://github.com/sanity-io/sanity-plugin-personalization/commit/d28d2cc7875c2addbfb749f55e69221822e035f5))
- made growthbook its own subpath export ([bcc1034](https://github.com/sanity-io/sanity-plugin-personalization/commit/bcc1034d4ed49327ac6e0250341964b1d1c673f5))
- new config option, updated experiment fetching ([ef300fb](https://github.com/sanity-io/sanity-plugin-personalization/commit/ef300fbcb2116e2b49a13a17195a09b6e479ea7e))

### Bug Fixes

- ensure that values are not duplicated ([52ab544](https://github.com/sanity-io/sanity-plugin-personalization/commit/52ab5441c175653ac075b7f4224c92f0363c38f6))
- get experiments from feature flags for growthbook and store values that will be used by FE ([eb40e0b](https://github.com/sanity-io/sanity-plugin-personalization/commit/eb40e0baeeb536cdf6a74f14dd5007c16e041426))
- only show secret input when finished loading ([a0eb18d](https://github.com/sanity-io/sanity-plugin-personalization/commit/a0eb18d494d4db3f92b09ce1b1edde846ee8c21d))
- resolved issue with too many re renders on experiments ([24f018e](https://github.com/sanity-io/sanity-plugin-personalization/commit/24f018ed3028ffd36f3b86975543a1a9cdca9239))
- updated base url to use corect api domain ([4d9b4f1](https://github.com/sanity-io/sanity-plugin-personalization/commit/4d9b4f1bc4c3acd15b0642a80efa364202239179))

## [2.2.1](https://github.com/sanity-io/sanity-plugin-personalization/compare/v2.2.0...v2.2.1) (2025-04-25)

### Bug Fixes

- works with content releases and removes variants if experiment changes" ([75c9a78](https://github.com/sanity-io/sanity-plugin-personalization/commit/75c9a78fb67feb9ab461c0c6f67943155e29ad2c))

## [2.2.0](https://github.com/sanity-io/sanity-plugin-personalization/compare/v2.1.0...v2.2.0) (2025-03-26)

### Features

- added message to warn there are no defeined experiments ([9302f08](https://github.com/sanity-io/sanity-plugin-personalization/commit/9302f0817327d33feb8ff26661ab18391fb4ff9d))

## [2.1.0](https://github.com/sanity-io/sanity-plugin-personalization/compare/v2.0.0...v2.1.0) (2025-02-21)

### Features

- added ability to copy default to a variant ([c1ff90a](https://github.com/sanity-io/sanity-plugin-personalization/commit/c1ff90a0cf000f8bb2fa455077d4a4e605820650))
- allow overiding of experiment and variant field names ([f42e75c](https://github.com/sanity-io/sanity-plugin-personalization/commit/f42e75c1643dee5074b5278742df086e4264c139))

## [2.0.0](https://github.com/sanity-io/sanity-plugin-personalization/compare/v1.1.1...v2.0.0) (2025-02-07)

### ⚠ BREAKING CHANGES

- use US english for repo name

### Features

- updated list preview to reflect experiment variants ([c479c65](https://github.com/sanity-io/sanity-plugin-personalization/commit/c479c654f91ef4897295ff2a1e43e52597b8f3f5))

### Documentation

- updated repo link ([79d0b02](https://github.com/sanity-io/sanity-plugin-personalization/commit/79d0b0245e3e17553b24ab6d555d9e6e51b1aba7))

## [1.1.1](https://github.com/sanity-io/sanity-plugin-personalisation/compare/v1.1.0...v1.1.1) (2025-01-02)

### Bug Fixes

- remove unneeded comments ([57d3d9a](https://github.com/sanity-io/sanity-plugin-personalisation/commit/57d3d9a16ed39296ca5d28a9d997e6856798c143))

## [1.1.0](https://github.com/sanity-io/sanity-plugin-personalisation/compare/v1.0.3...v1.1.0) (2024-12-09)

### Features

- allow canary branch to make releases ([936068d](https://github.com/sanity-io/sanity-plugin-personalisation/commit/936068dd392074c62821f5ab2ba4bbcfb34a9489))

### Bug Fixes

- use onchagne from props rather than document operation for patch ([b61cdce](https://github.com/sanity-io/sanity-plugin-personalisation/commit/b61cdce12e470125fe70293bce983f48d091ade6))

## [1.0.3](https://github.com/sanity-io/sanity-plugin-personalisation/compare/v1.0.2...v1.0.3) (2024-11-26)

### Bug Fixes

- updated plugin name to match scoped package ([d0eb0cc](https://github.com/sanity-io/sanity-plugin-personalisation/commit/d0eb0cc930a9d1a4c2c38ff35bc68eafb8435ebc))

## [1.0.2](https://github.com/sanity-io/sanity-plugin-personalisation/compare/v1.0.1...v1.0.2) (2024-11-26)

### Bug Fixes

- updated name of package in readme ([847a8a1](https://github.com/sanity-io/sanity-plugin-personalisation/commit/847a8a1f04e24a7421381490a0d31020cc30dff3))

## [1.0.1](https://github.com/sanity-io/sanity-plugin-personalisation/compare/v1.0.0...v1.0.1) (2024-11-25)

### Bug Fixes

- update relase workflow ([a991386](https://github.com/sanity-io/sanity-plugin-personalisation/commit/a991386ee97142ec91f1a01a81acd135ccbe74ef))

## 1.0.0 (2024-11-25)

### Features

- updated name of package ([881e19f](https://github.com/sanity-io/sanity-plugin-personalisation/commit/881e19f001cbd4be6df12bc8b45f8a9d5f263311))

### Bug Fixes

- add field action to show hide extra experiment data ([f4cdf44](https://github.com/sanity-io/sanity-plugin-personalisation/commit/f4cdf44a83b56fb6c29f705e4b4ebe02c938f1d1))
- add field action to show hide extra experiment data ([810e913](https://github.com/sanity-io/sanity-plugin-personalisation/commit/810e913b325e45ff9f689f3b56ae74abc87dd9fc))
- on removal of experiment clear additional fields ([d2613a3](https://github.com/sanity-io/sanity-plugin-personalisation/commit/d2613a369e237861519fb857fff585c5f4b9e8db))
Loading
Loading