HideProperty Attribute

Attribute to hide a field in the inspector but still show it in debug view.

Example:

using UnityEngine;
using EditorAttributes;

public class AttributesExample : MonoBehaviour
{
        [HideProperty] public int field;
}

Normal inspector mode:

../../_images/HideProperty01.png

Debug inspector mode:

../../_images/HideProperty02.png

The intended usage for this attribute is for fields grouped by the Grouping Attributes, since you need to hide the original fields else they will be shown twice, hiding them with the HideInInspector Attribute works well but this will also hide them in Debug View which might not be ideal.