microsoft / fluentui-system-icons

Fluent System Icons are a collection of familiar, friendly and modern icons from Microsoft.
https://aka.ms/fluentui-system-icons
MIT License
5.65k stars 498 forks source link

Supporting RSC in react-icons package #606

Open gadingnst opened 12 months ago

gadingnst commented 12 months ago

we have used these icons in our Design System.

but. when we use NextJS 13 with App Router, we can't import the icon directly in RSC like:

import { DismissSquareRegular } from `@fluentui/react-icons`;

function ListingWalletHeader() {
  return (
    <div className="flex items-center">
      ...
      <DismissSquareRegular />
    </div>
  );
}

it will return an error like this: Screenshot 2023-07-13 at 06 03 57

can we develop the icons to support RSC feature? maybe we just create the icon SVG without createContext? maybe just like this