New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@primer/component-metadata

Package Overview
Dependencies
Maintainers
11
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@primer/component-metadata

[![npm](https://img.shields.io/npm/v/@primer/component-metadata)](https://www.npmjs.com/package/@primer/component-metadata) [![CI](https://github.com/primer/component-metadata/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/primer/comp

  • 0.5.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
11
Created
Source

Primer Component Metadata

npm CI

🚧 Work in progress. Expect frequent breaking changes.

A place to store component metadata shared across all implementations of Primer.

Installation

Install with npm or yarn:

npm install @primer/component-metadata
yarn add @primer/component-metadata

Usage

import metadata from "@primer/component-metadata";

metadata.components.progress_bar;
// {
//   id: 'progress_bar',
//   displayName: 'Progress bar',
//   description: 'Use progress bars to visualize task completion.',
//   implementations: {
//     react: 'https://primer.style/components/ProgressBar',
//     viewComponent: 'https://primer.style/view-components/components/progressbar',
//     css: 'https://primer.style/css/components/progress'
//   }
// }

Metadata

Each component should have the following metadata:

NameDescriptionGuidelines
id (required)A unqiue string used to identify the componentThe id of the component should be the component name in snake case (e.g. "progress_bar")
displayName (required)The name of the componentUse sentence case (e.g. "Progress bar")
description (required)Describe how the component should be usedUse active voice (e.g. "Use progress bars to ..." not "Progress bars are used to ...")
guidelinesURL to design guidelines for the component
implementations.reactURL to React implementation of the component
implementations.viewComponentURL to ViewComponent implementation of the component
implementations.cssURL to CSS impelementation of the component
implementations.figmaURL to Figma implementation of the component

FAQs

Package last updated on 08 Nov 2022

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc