👀 Our most exciting product launch yet 🚀 Join us May 8th for Sanity Connect

Clarification on attribute count in Sanity.io for nested objects with different keys.

5 replies
Last updated: Mar 14, 2024
Hi there,I need a help regrading attribute limit count . As I have reached my max limit of 4k in sanity so just need to confirm one thing regarding unique paths

Let's say I have 2 documents and in each document fields are almost same but they are nested under different objects .

For Example:-
1.
Page1:{ title:'Sanity' ,subtitle:'Sanity'}
2.
Page2:{title:'Sanity' , subtitle:'Sanity'}
So in the above example the attribute count would be 6 or is it 3 ?
Mar 12, 2024, 8:11 AM
Are page 1 and page 2 different
_types
?
Mar 12, 2024, 4:29 PM
Hey
user M
Actually its not Page1 and Page2. They both fall under _type "Page" which is array of objects and each object has a different name but same fields in it so It will create unique path always which increases my attribute count right ?For Example
Page:[
{
object_1_name:{ title:'Sanity', subtitle:'Astro'}
},

{
object_2_name
:{title:'Sanity' , subtitle:'Astro'}}
]
Mar 13, 2024, 7:04 AM
So here attribute count will be different for first and second object because key_name is different ? Total for first - 3 and for second - 3
Mar 13, 2024, 7:05 AM
Ah yes, since they’re under a different key in the object, each will be a unique path.
Mar 13, 2024, 3:57 PM
Thanks for help
Mar 14, 2024, 5:38 AM

Sanity– build remarkable experiences at scale

Sanity is a modern headless CMS that treats content as data to power your digital business. Free to get started, and pay-as-you-go on all plans.

Was this answer helpful?