<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Posts tagged #react</title><description>All posts tagged with react on queen.raae.codes</description><link>https://queen.raae.codes/tag/react/</link><item><title>📝 ✨ ~ Framer Code Override Not Showing? Add ComponentType</title><link>https://queen.raae.codes/2025-12-18-framer-overries-not-showing-up/</link><guid isPermaLink="true">https://queen.raae.codes/2025-12-18-framer-overries-not-showing-up/</guid><description>I&apos;ve seen this question pop up in the Framer community more than a few times: &quot;I wrote a code override, but it&apos;s not showing up in the dropdown!&quot; 😤 It&apos;s…</description><pubDate>Thu, 18 Dec 2025 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I&apos;ve seen this question pop up in the &lt;a href=&quot;https://framer.link/queen-raae&quot;&gt;Framer&lt;/a&gt; community more than a &lt;a href=&quot;https://www.framer.community/c/developers/need-help-override-not-showing-in-dropdown-menu&quot;&gt;few times&lt;/a&gt;: &amp;quot;I wrote a code override, but it&apos;s not showing up in the dropdown!&amp;quot; 😤&lt;/p&gt;
&lt;p&gt;It&apos;s frustrating because the code looks right, it&apos;s in the right place, but Framer just... ignores it. Something I also personally experienced when creating my first &lt;a href=&quot;https://outseta.com/?via=queen&quot;&gt;Outseta&lt;/a&gt; code overrides.&lt;/p&gt;
&lt;h2&gt;The Problem&lt;/h2&gt;
&lt;p&gt;Here&apos;s what usually happens. You write what feels like a perfectly reasonable code override:&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;language-typescript&quot;&gt;// ❌ This won&apos;t show up in the override panel
import { forwardRef } from &amp;quot;react&amp;quot;;

export const WithClick = (Component) =&amp;gt; {
  return forwardRef((props, ref) =&amp;gt; {
    const handleClick = () =&amp;gt; {
      console.log(&amp;quot;Clicked!&amp;quot;);
    };

    return &amp;lt;Component {...props} ref={ref} onClick={handleClick} /&amp;gt;;
  });
};
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;You save the file, go back to the Framer canvas, and... nothing. The override doesn&apos;t appear in the dropdown. No error message, no explanation. It&apos;s like your code doesn&apos;t even exist.&lt;/p&gt;
&lt;h2&gt;The Solution&lt;/h2&gt;
&lt;p&gt;Framer has specific requirements for code overrides to show up in the panel. It&apos;s not just about writing a function - the function needs to follow a particular &lt;strong&gt;signature&lt;/strong&gt; that Framer recognizes.&lt;/p&gt;
&lt;p&gt;Specifically, code overrides must be properly typed with React&apos;s &lt;code&gt;ComponentType&lt;/code&gt; as the return type.&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;language-typescript&quot;&gt;// ✅ This will show up in the override panel
import { forwardRef, ComponentType } from &amp;quot;react&amp;quot;;

export const WithClick = (Component): ComponentType =&amp;gt; {
  return forwardRef((props, ref) =&amp;gt; {
    const handleClick = () =&amp;gt; {
      console.log(&amp;quot;Clicked!&amp;quot;);
    };

    return &amp;lt;Component {...props} ref={ref} onClick={handleClick} /&amp;gt;;
  });
};
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;That&apos;s it. The &lt;code&gt;ComponentType&lt;/code&gt; return type annotation is what tells Framer &amp;quot;hey, this is a valid override!&amp;quot; Without it, Framer has no way to know your function is meant to be an override.&lt;/p&gt;
&lt;p&gt;This isn&apos;t really explained in the error messages (because there are no error messages 🤦‍♀️), and it&apos;s not super obvious from the docs either. But once you know it, it makes sense and now you know 🥳&lt;/p&gt;
</content:encoded></item><item><title>📝 ✨ ~ Copy current URL with a Framer Code Override</title><link>https://queen.raae.codes/2025-10-27-framer-copy-button/</link><guid isPermaLink="true">https://queen.raae.codes/2025-10-27-framer-copy-button/</guid><description>I&apos;ve been browsing the Framer community forum lately as I&apos;m working on an updated Outseta Framer Plugin. There I found a question about how to add a &quot;copy…</description><pubDate>Mon, 27 Oct 2025 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I&apos;ve been browsing the &lt;a href=&quot;https://framer.link/queen-raae&quot;&gt;Framer&lt;/a&gt; community forum lately as I&apos;m working on an updated &lt;a href=&quot;https://outseta.com/?via=queen&quot;&gt;Outseta&lt;/a&gt; &lt;a href=&quot;https://framer.link/outseta-plugin&quot;&gt;Framer Plugin&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;There I found a &lt;a href=&quot;https://www.framer.community/c/developers/copy-current-page-link-button-cms-supported&quot;&gt;question about how to add a &amp;quot;copy link&amp;quot; code override&lt;/a&gt; and threw together a code override.&lt;/p&gt;
&lt;h2&gt;What are Code Overrides?&lt;/h2&gt;
&lt;p&gt;Code overrides are Higher Order React Components that wrap around &amp;quot;stuff&amp;quot; on the Framer canvas. So if you are a React developer, you can use code overrides to add all sorts of functionality to a Framer site.&lt;/p&gt;
&lt;p&gt;Framer is really onto something here with seperating design from functionality 🤩&lt;/p&gt;
&lt;h2&gt;The Ask&lt;/h2&gt;
&lt;p&gt;Copy the current page URL to the clipboard with a Code Override.&lt;/p&gt;
&lt;h2&gt;The Solution&lt;/h2&gt;
&lt;p&gt;A lightweight Code Override that adds copy-to-clipboard functionality to any element.&lt;/p&gt;
&lt;h2&gt;The Code&lt;/h2&gt;
&lt;pre&gt;&lt;code class=&quot;language-typescript&quot;&gt;import { forwardRef, type ComponentType } from &amp;quot;react&amp;quot;;

export function withCopyURL(Component): ComponentType {
  return forwardRef((props, ref) =&amp;gt; {
    const handleClick = async () =&amp;gt; {
      try {
        const currentURL = window.location.href;
        await navigator.clipboard.writeText(currentURL);
        console.log(&amp;quot;URL copied to clipboard:&amp;quot;, currentURL);
      } catch (err) {
        console.error(&amp;quot;Failed to copy URL:&amp;quot;, err);
      }
    };

    return &amp;lt;Component ref={ref} {...props} onClick={handleClick} style={{ cursor: &amp;quot;pointer&amp;quot; }} /&amp;gt;;
  });
}
&lt;/code&gt;&lt;/pre&gt;
&lt;h2&gt;How to Use It&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;In Framer, open the &lt;strong&gt;Assets&lt;/strong&gt; panel and go to the &lt;strong&gt;Code&lt;/strong&gt; tab&lt;/li&gt;
&lt;li&gt;Click the &lt;strong&gt;+&lt;/strong&gt; button to create a new Code Override file and name it&lt;/li&gt;
&lt;li&gt;Paste the code above into the file&lt;/li&gt;
&lt;li&gt;Select any element on your canvas (a button, icon, or text layer)&lt;/li&gt;
&lt;li&gt;In the properties panel, find &lt;strong&gt;Code Override&lt;/strong&gt; and select &lt;code&gt;withCopyURL&lt;/code&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;That&apos;s it! Now when someone clicks that element, the current page URL gets copied to their clipboard.&lt;/p&gt;
&lt;p&gt;You can add visual feedback like hover states or tap animation in the Framer canvas.&lt;/p&gt;
&lt;h2&gt;Going Further&lt;/h2&gt;
&lt;p&gt;You could extend this Code Override to:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Show a toast notification after copying (&amp;quot;Link copied!&amp;quot;)&lt;/li&gt;
&lt;li&gt;Copy a custom URL instead of the current one (great for referral links)&lt;/li&gt;
&lt;li&gt;Track copy events in your analytics&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt; 
&lt;strong&gt;PS:&lt;/strong&gt; The Clipboard API works in all modern browsers, but it requires a secure context (HTTPS). It&apos;ll work fine on your published Framer site, but might act up on localhost without HTTPS.&lt;/p&gt;
&lt;br/&gt;&lt;ul&gt;&lt;li&gt;Queen Raae works part-time as Outseta&apos;s Developer Advocate.&lt;/li&gt;&lt;/ul&gt;</content:encoded></item><item><title>📝 ✨ ~ Kind of annoyed at React​</title><link>https://queen.raae.codes/2024-01-18-annoyed-at-react/</link><guid isPermaLink="true">https://queen.raae.codes/2024-01-18-annoyed-at-react/</guid><description>Last week, Cassidy Williams wrote Kind of annoyed at React, and I wholeheartedly agree with her train of thought. In it, she mentioned that the latest React…</description><pubDate>Thu, 18 Jan 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Last week, Cassidy Williams wrote &lt;a href=&quot;https://blog.cassidoo.co/post/annoyed-at-react/&quot;&gt;Kind of annoyed at React&lt;/a&gt;, and I wholeheartedly agree with her train of thought.&lt;/p&gt;
&lt;p&gt;In it, she mentioned that the latest &lt;a href=&quot;https://github.com/facebook/react/releases/tag/v18.2.0&quot;&gt;React&lt;/a&gt; release was in June 2022 🤯&lt;/p&gt;
&lt;p&gt;That made me peek at the release note again, reminding me that React Server Components (RSC) are still experimental.&lt;/p&gt;
&lt;p&gt;And together with experiences like:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Every time a new developer picked up our codebase, the questions came up: “What’s running on the server? What’s running on the client?” Every PR had feedback regarding something accidentally/unnecessarily shipped to the client.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;mentioned in &lt;a href=&quot;https://www.mux.com/blog/what-are-react-server-components&quot;&gt;​Everything I Wish I Knew before moving 50,000 lines of code to React Server Components​&lt;/a&gt; it makes me cautious, very cautious.&lt;/p&gt;
&lt;p&gt;But it&apos;s always a good idea to try to understand a concept, and for that, I recommend Josh Comeau&apos;s post &lt;a href=&quot;https://www.joshwcomeau.com/react/server-components/&quot;&gt;Making Sense of React Server Components&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;🤔&lt;/p&gt;
</content:encoded></item><item><title>📝 ✨ ~ How to style `dangerouslySetInnerHTML` with Tailwind</title><link>https://queen.raae.codes/2023-03-22-tailwind-children/</link><guid isPermaLink="true">https://queen.raae.codes/2023-03-22-tailwind-children/</guid><description>I stumbled on this challenge when working with highlighting for Prune your Follows. How to style the mark element in the possibly highlighted search result?…</description><pubDate>Wed, 22 Mar 2023 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I stumbled on this challenge when working with highlighting for &lt;a href=&quot;https://pruneyourfollows.com/&quot;&gt;Prune your Follows&lt;/a&gt;.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;How to style the &lt;code&gt;mark&lt;/code&gt; element in the possibly highlighted search result?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Turns out Tailwind has support for &lt;a href=&quot;https://tailwindcss.com/docs/hover-focus-and-other-states#using-arbitrary-variants&quot;&gt;Using arbitrary variants&lt;/a&gt;, but it took me quite a while to find that in the documentation, I&apos;ll tell you 🕵️‍♀️&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;language-jsx&quot;&gt;const HighlighetResult = () =&amp;gt; {
  return (
    &amp;lt;span
      className=&amp;quot;[&amp;amp;&amp;gt;em]:bg-amber-300&amp;quot; // 👈👈👈
      dangerouslySetInnerHTML={{
        __html: highlight?.username || record.username,
      }}
    /&amp;gt;
  );
};
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Inside the &lt;code&gt;[]&lt;/code&gt; in the code example, you may use any regular old css selector! So, for instance, if you are getting content from a third party, you could do &lt;code&gt;[&amp;amp;&amp;gt;p]&lt;/code&gt;, &lt;code&gt;[&amp;amp;&amp;gt;img]&lt;/code&gt; etc. The &lt;code&gt;&amp;gt;&lt;/code&gt; indicates direct descendant; for any &lt;code&gt;img&lt;/code&gt; you&apos;ll need to do &lt;code&gt;[&amp;amp;_img], the &lt;/code&gt;_` will be read as a space.&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;./higlighting.png&quot; alt=&quot;The resulting styled highlight&quot;&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;All the best,&lt;br&gt;
Queen Raae&lt;/p&gt;
</content:encoded></item><item><title>📝 ✨ ~ Styling broken images (with Tailwind and React)</title><link>https://queen.raae.codes/2022-11-26-broken-images/</link><guid isPermaLink="true">https://queen.raae.codes/2022-11-26-broken-images/</guid><description>After using pruneyourfollows.com for a couple of weeks, I started seeing broken image avatars. The app does not import data for unfollowed accounts; at some…</description><pubDate>Sat, 26 Nov 2022 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;After using &lt;a href=&quot;https://pruneyourfollows.com&quot;&gt;pruneyourfollows.com&lt;/a&gt; for a couple of weeks, I started seeing broken image avatars. The app does not import data for unfollowed accounts; at some point, the imported image avatars break, and it look like this:&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;./broken-image.png&quot; alt=&quot;Broken image looking bad&quot;&gt;&lt;/p&gt;
&lt;p&gt;Shai Schechter to the rescue! He climbed onboard for Friday&apos;s &lt;a href=&quot;https://youtu.be/7FiUfiyJXt8&quot;&gt;unauthorized and rum-fueled treasure hunt&lt;/a&gt; in the sharky waters around the Gatsby islands to help us out.&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;./screen-dump.png&quot; alt=&quot;Screendump of stream&quot;&gt;&lt;/p&gt;
&lt;p&gt;He proposed listing for the image&apos;s load and error events to determine its status. It also meant we could add a nice pulsating style while loading.&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;language-jsx&quot;&gt;import clsx from &amp;quot;clsx&amp;quot;;
import React, { useState } from &amp;quot;react&amp;quot;;

export function Avatar({ imageUrl, altText, className }) {
  const [status, setStatus] = useState(&amp;quot;loading&amp;quot;);

  const handleOnLoad = () =&amp;gt; {
    setStatus(&amp;quot;fulfilled&amp;quot;);
  };

  const handleOnError = () =&amp;gt; {
    setStatus(&amp;quot;failed&amp;quot;);
  };

  return (
    &amp;lt;div
      className={clsx(
        &amp;quot;overflow-hidden rounded-full border bg-slate-400&amp;quot;,
        status === &amp;quot;loading&amp;quot; ? &amp;quot;animate-pulse&amp;quot; : &amp;quot;&amp;quot;,
        className
      )}
    &amp;gt;
      &amp;lt;img
        className={clsx(
          status === &amp;quot;fulfilled&amp;quot; ? &amp;quot;visible&amp;quot; : &amp;quot;hidden&amp;quot;,
          &amp;quot;w-full&amp;quot;
        )}
        src={imageUrl}
        alt={altText}
        onLoad={handleOnLoad}
        onError={handleOnError}
      /&amp;gt;
    &amp;lt;/div&amp;gt;
  );
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Full disclosure: I set it up as &lt;code&gt;status === &amp;quot;failed&amp;quot; ? &amp;quot;hidden&amp;quot; : &amp;quot;visible&amp;quot;&lt;/code&gt; (flipped logic) to begin with, but that resulted in a flicker of a broken image and, to be honest, hiding until success makes much more sense!&lt;/p&gt;
&lt;p&gt;All the best,&lt;br&gt;
Queen Raae&lt;/p&gt;
</content:encoded></item><item><title>🧙‍♀️ 🧱 ~ A little semantic HTML trick for React components</title><link>https://queen.raae.codes/2022-10-10-semantic-react/</link><guid isPermaLink="true">https://queen.raae.codes/2022-10-10-semantic-react/</guid><description>Learn more about 24 Semantic HTML Elements this advent by signing up for Semantic Advent that will run again in 2024. Semantic HTML is the foundation of a web…</description><pubDate>Mon, 10 Oct 2022 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;&amp;lt;aside class=&amp;quot;notice&amp;quot;&amp;gt;&lt;/p&gt;
&lt;p&gt;Learn more about 24 Semantic HTML Elements this advent by signing up for &lt;a href=&quot;https://advent.raae.codes&quot;&gt;Semantic Advent&lt;/a&gt; that will run again in 2024.&lt;/p&gt;
&lt;p&gt;&amp;lt;/aside&amp;gt;&lt;/p&gt;
&lt;p&gt;Semantic HTML is the foundation of a web project. It helps assistive technologies and Google make sense of your site.&lt;/p&gt;
&lt;p&gt;What is semantic HTML? &lt;code&gt;article&lt;/code&gt;, &lt;code&gt;heading&lt;/code&gt;, &lt;code&gt;h2&lt;/code&gt;, &lt;code&gt;aside&lt;/code&gt;, &lt;code&gt;ul&lt;/code&gt;, &lt;code&gt;section&lt;/code&gt; etc. all have semantic meaning. It says something about the content inside them. If the content is a stand-alone piece of content, use &lt;code&gt;article&lt;/code&gt;; if it&apos;s a list, use &lt;code&gt;ul&lt;/code&gt;, and so on. In comparison, &lt;code&gt;div&lt;/code&gt; and &lt;code&gt;span&lt;/code&gt; have no semantic meaning.&lt;/p&gt;
&lt;p&gt;To lean more about check out &lt;a href=&quot;https://web.dev/learn/html/semantic-html/&quot;&gt;web.dev&apos;s article on Semantic HTML&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Unfortunately, adherence to semantic HTML often gets lost when creating reusable React UI components.&lt;/p&gt;
&lt;p&gt;Let&apos;s say we make a reusable card component.&lt;/p&gt;
&lt;p&gt;It could look something like this:&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;language-jsx&quot;&gt;// File: card.js
import React from &amp;quot;react&amp;quot;;

export function Card(props) {
  const { children } = props;
  return &amp;lt;div&amp;gt;{children}&amp;lt;/div&amp;gt;;
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;It makes sense not to give the design of the content (a card) any semantic meaning by using a &lt;code&gt;div&lt;/code&gt;. However, such a component is very often used semantically.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;As a list of blog posts =&amp;gt; &lt;code&gt;article&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;As a call out in an article =&amp;gt; &lt;code&gt;aside&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;To spice up the design of a paragraph =&amp;gt; &lt;code&gt;p&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;We can solve the issue by surrounding the card with the correct semantic element:&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;language-jsx&quot;&gt;// File: exmaple.js
import React from &amp;quot;react&amp;quot;;
import { Card } from &amp;quot;./card&amp;quot;;

export function Example() {
  return (
    &amp;lt;article&amp;gt;
      &amp;lt;p&amp;gt;An introduction&amp;lt;/p&amp;gt;
      &amp;lt;aside&amp;gt;
        &amp;lt;Card&amp;gt;
          Something related to the article but a little outside of the normal
          flow.
        &amp;lt;/Card&amp;gt;
      &amp;lt;/aside&amp;gt;
      &amp;lt;p&amp;gt;More content...&amp;lt;/p&amp;gt;
      &amp;lt;p&amp;gt;
        &amp;lt;Card&amp;gt;A paragraph with different styling...&amp;lt;/Card&amp;gt;
      &amp;lt;/p&amp;gt;
      &amp;lt;p&amp;gt;More content...&amp;lt;/p&amp;gt;
    &amp;lt;/article&amp;gt;
  );
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;But we&apos;ll be notified that a &lt;code&gt;div&lt;/code&gt; is not a valid child of &lt;code&gt;p&lt;/code&gt;, and the approach feels iffy. At least to me 🤪&lt;/p&gt;
&lt;h2&gt;The semantic HTML trick for React components!&lt;/h2&gt;
&lt;p&gt;&amp;lt;aside class=&amp;quot;notice&amp;quot;&amp;gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;There was an error earlier in the example code caught by &lt;a href=&quot;https://www.reddit.com/r/reactjs/comments/y19t4k/comment/irx1z7z/?utm_source=reddit&amp;amp;utm_medium=web2x&amp;amp;context=3&quot;&gt;GasimGasimzada on Reddit&lt;/a&gt; Thank you!&lt;/li&gt;
&lt;li&gt;&lt;code&gt;as&lt;/code&gt; is a better prop name than &lt;code&gt;element&lt;/code&gt;, as suggested by several &lt;a href=&quot;https://www.reddit.com/r/reactjs/comments/y19t4k/comment/irzwyr5/?context=3&quot;&gt;commentators on Reddit&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&amp;lt;/aside&amp;gt;&lt;/p&gt;
&lt;p&gt;Make the semantic HTML element configurable:&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;language-jsx&quot;&gt;// File: card.js
import React from &amp;quot;react&amp;quot;;

export function Card(props) {
  // 1️⃣ Destructure element and children from props
  const { element, children } = props;

  // 2️⃣ Capitalise element to make it valid jsx
  let Element = element;

  // 3️⃣ Make &amp;quot;div&amp;quot; the default choice
  if (!element) {
    Element = &amp;quot;div&amp;quot;;
  }

  return &amp;lt;Element&amp;gt;{children}&amp;lt;/Element&amp;gt;;
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Or in shorthand form:&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;language-jsx&quot;&gt;import React from &amp;quot;react&amp;quot;;

export function Card(props) {
  // Do 1️⃣, 2️⃣, 3️⃣ in one line
  const { element: Element = &amp;quot;div&amp;quot;, children } = props;

  return &amp;lt;Element&amp;gt;{children}&amp;lt;/Element&amp;gt;;
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;You may then use the Card component like so:&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;language-jsx&quot;&gt;// File: exmaple.js
import React from &amp;quot;react&amp;quot;;
import { Card } from &amp;quot;./card&amp;quot;;

export function Example() {
  return (
    &amp;lt;article&amp;gt;
      &amp;lt;p&amp;gt;An introduction&amp;lt;/p&amp;gt;

      &amp;lt;Card element=&amp;quot;aside&amp;quot;&amp;gt;
        Something related to the article but a little outside of the normal
        flow.
      &amp;lt;/Card&amp;gt;

      &amp;lt;p&amp;gt;More content...&amp;lt;/p&amp;gt;

      &amp;lt;Card element=&amp;quot;p&amp;quot;&amp;gt;A paragraph with different styling...&amp;lt;/Card&amp;gt;

      &amp;lt;p&amp;gt;More content...&amp;lt;/p&amp;gt;
    &amp;lt;/article&amp;gt;
  );
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Credit where credit is due. I learned how to do this by looking at &lt;a href=&quot;https://github.com/mui/material-ui&quot;&gt;MUI&apos;s source code&lt;/a&gt;!&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;All the best,&lt;br&gt;
Queen Raae&lt;/p&gt;
</content:encoded></item></channel></rss>