---
title: safeAttributes
description: >-
  `element`'s HTML attributes without event handlers, `srcdoc`, or script and
  HTML-document URLs.
updated_at: '2026-11-19T09:51:44+01:00'
created_at: '2026-11-12T12:04:45+01:00'
symbol:
  kind: function
  name: safeAttributes
  signatures:
    - 'safeAttributes(element: Element): Record<string, string | boolean>'
  parameters:
    - name: element
      type: Element
  returns:
    type: 'Record<string, string | boolean>'
  source: >-
    https://github.com/mia-cx/svartz/blob/711f3906a713c8b9a5a572d0f34c85e90c3bc3d1/packages/plugins/src/content.ts#L40
---

# safeAttributes
