Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More

@react-types/shared

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@react-types/shared

Spectrum UI components in React


Version published
Weekly downloads
3.4M
decreased by-8.02%
Maintainers
2
Weekly downloads
 
Created

What is @react-types/shared?

@react-types/shared is a TypeScript utility library that provides shared types and interfaces for React components. It is part of the React Spectrum collection of libraries, which are designed to work together to build accessible, performant, and robust user interfaces.

What are @react-types/shared's main functionalities?

DOMProps

The DOMProps interface defines common properties that can be applied to any DOM element, such as id, className, and style.

interface DOMProps {
  id?: string;
  className?: string;
  style?: React.CSSProperties;
}

AriaLabelingProps

The AriaLabelingProps interface defines properties for ARIA labeling, which are used to improve accessibility by providing additional context to screen readers.

interface AriaLabelingProps {
  'aria-label'?: string;
  'aria-labelledby'?: string;
  'aria-describedby'?: string;
}

StyleProps

The StyleProps interface defines common style properties that can be applied to components, such as margin, padding, and border.

interface StyleProps {
  margin?: string | number;
  padding?: string | number;
  border?: string;
}

Other packages similar to @react-types/shared

FAQs

Package last updated on 04 Aug 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts