NoA IgniteAccelerator Docs
Contact ↗
GitHubGitHub
  • Get Started
      • Context
      • PaymentEmbed
      • createRenderBlock
      • createRequiredContext
      • createSvgIcon
      • getReactElementRef
      • isRefObject
      • setRef
      • useElementSize
      • useFocusReturn
      • useForkRef
      • useInert
      • useIntersectionObserver
      • useInterval
      • useIsomorphicEffect
      • useMediaQuery
      • useMutationObserver
      • useRTL
      • useResizeObserver
      • useSticky
      • useTimeout
      • useVisualViewport
      • useWindowSize
      • typography
      • AnyFunction
      • Concatenate
      • DistributiveOmit
      • HintedNumber
      • HintedString
      • KeyOfAny
      • MapKeys
      • Maybe
      • OverridableStringUnion
      • Overwrite
      • Prettify
      • PropsFrom
      • Repeat
      • Split
      • WithFallback
      • Writeable
      • assert
      • calculateContrast
      • calculateLuminance
      • capitalize
      • clamp
      • colorContrast
      • deepmerge
      • hexToRGB
      • isObject
      • isPlainObject
      • lerp
      • mapRange
      • normalize
      • omit
      • pick
      • range
      • sleep

On This Page

  • createSvgIcon
  • Example
Question? Give us feedback →
@noaignitereact-utilscreateSvgIcon

createSvgIcon

Create a new SVG icon component.

  • @param path - The SVG path to render.
  • @param displayName - The display name of the icon.
  • @param viewBox - The viewBox of the SVG.
  • @param rest - Additional props to pass to the SVG element.
  • @returns A new SVG icon component.

Example

export const AddIcon = createSvgIcon(
  <path d="M19 13H13V19H11V13H5V11H11V5H13V11H19V13Z" />,
  'Add',
);
createRequiredContextgetReactElementRef

Accelerator Docs