
Security News
npm Adopts OIDC for Trusted Publishing in CI/CD Workflows
npm now supports Trusted Publishing with OIDC, enabling secure package publishing directly from CI/CD workflows without relying on long-lived tokens.
@cloudflare/elements
Advanced tools
Props-based styling hooked into the Cloudflare design system.
Installation with yarn is recommended
$ yarn add @cloudflare/elements
elements
is a method of styling closely resembling writing semantic HTML, leading to greater readability. Because it uses styled-system under the hood, elements
is able to work with most css-in-js libraries and greater enforce constraint-based styling.
For pseudo-class usage, you'll want to default to usage of createComponent
from @cloudflare/style-container
.
For guidelines on responsive styling, read the styled-system guidelines on styles.
Certain elements, such as <Button />
and <Select />
have counterparts in Component Library. To reduce confusion around when to use elements
versus Component Library, a general rule of thumb is: if it looks like a Component Library component, it's best to use Component Library. If you need alternate styling but semantically require the specified DOM element (ex: <button />
) then use elements
. There will be ongoing work to rewrite Component Library using elements
, thus this reduces the amount of maintenance needed.
FAQs
Cloudflare Styled Elements
We found that @cloudflare/elements demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 40 open source maintainers collaborating on the project.
Did you know?
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.
Security News
npm now supports Trusted Publishing with OIDC, enabling secure package publishing directly from CI/CD workflows without relying on long-lived tokens.
Research
/Security News
A RubyGems malware campaign used 60 malicious packages posing as automation tools to steal credentials from social media and marketing tool users.
Security News
The CNA Scorecard ranks CVE issuers by data completeness, revealing major gaps in patch info and software identifiers across thousands of vulnerabilities.