Skip to content

Commit

Permalink
Remove title, as it is pass through by default
Browse files Browse the repository at this point in the history
  • Loading branch information
davidjbradshaw committed Aug 30, 2024
1 parent 0afea2e commit 4150a03
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/react/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ import warning from 'warning'

import filterIframeAttribs from '../common/filter-iframe-attribs'

// TODO: Add support for React.forwardRef() in next major version
function IframeResizer(props) {
// eslint-disable-next-line react/prop-types
const { title, forwardRef, ...rest } = props
const { forwardRef, ...rest } = props
const filteredProps = filterIframeAttribs(rest)
const iframeRef = useRef(null)

Expand Down Expand Up @@ -37,7 +38,8 @@ function IframeResizer(props) {
},
}))

return <iframe title={title} {...filteredProps} ref={iframeRef} />
// eslint-disable-next-line jsx-a11y/iframe-has-title
return <iframe {...filteredProps} ref={iframeRef} />
}

export default IframeResizer

0 comments on commit 4150a03

Please sign in to comment.