Attachments

The Native SDK allows you to attach a view-hierarchy.json file that follows the structure described in RFC#33. This is mainly meant for downstream SDKs (e.g., sentry-godot).

To add a view hierarchy attachment, the path to the file has to be configured when initializing the SDK. It will monitor the file and upload it along with any event or crash that is sent to Sentry:

Copied
sentry_options_add_view_hierarchy(options, "./view-hierarchy.json");

Along with the file appearing in the Attachments tab, it is visualized on the issue as such:

View Hierarchy Example

Was this helpful?
Help improve this content
Our documentation is open source and available on GitHub. Your contributions are welcome, whether fixing a typo (drat!) or suggesting an update ("yeah, this would be better").