fix: Bad functional refactor

This commit is contained in:
Tom Moor committed 2022-10-10 07:47:35 -04:00
1 parent 73b604cd9d
commit 2f2e367e91
1 file changed
+1 -1
+1 -1
View File
@@ -6,7 +6,7 @@ const URL_REGEX = new RegExp("^https://codepen.io/(.*?)/(pen|embed)/(.*)$");
export default function Codepen(props: Props) {
const normalizedUrl = props.attrs.href.replace(/\/pen\//, "/embed/");
return <Frame {...this.props} src={normalizedUrl} title="Codepen Embed" />;
return <Frame {...props} src={normalizedUrl} title="Codepen Embed" />;
}
Codepen.ENABLED = [URL_REGEX];