npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

tailwindcss-smooth-corners

v0.1.1

Published

A Tailwind CSS plugin that applies smooth superellipse corner shapes to rounded utilities without rewriting components.

Readme

tailwindcss-smooth-corners

tailwindcss-smooth-corners is a Tailwind CSS v4 plugin that makes Tailwind's rounded-* utilities render with smoother, iOS-style corners using CSS corner-shape.

If you already use classes like rounded-lg, rounded-2xl, or rounded-[24px], this plugin works on top of them. You do not need to learn a new radius system first.

What This Plugin Does

Normally, Tailwind's rounded utilities only set border-radius.

This plugin keeps border-radius, then adds corner-shape as a progressive enhancement:

  • supported browsers get smoother superellipse corners
  • unsupported browsers keep normal rounded corners

That means the fallback is already built in.

Install

npm install tailwindcss-smooth-corners

You can also use:

pnpm add tailwindcss-smooth-corners
yarn add tailwindcss-smooth-corners
bun add tailwindcss-smooth-corners

Quick Start

Add the plugin to your main CSS file:

@import "tailwindcss";
@plugin "tailwindcss-smooth-corners";

That is enough to get started.

Now your existing classes will work like this:

<div class="rounded-xl"></div>
<button class="rounded-full"></button>
<div class="rounded-[24px]"></div>

By default, the plugin uses:

superellipse(2)

Beginner Explanation

Think of it like this:

  • border-radius decides how round the corner is
  • corner-shape decides the style of that curve

This plugin keeps Tailwind in charge of the radius, and adds a smoother shape on top.

Changing The Default Shape

If you want a different default shape for the whole project, configure it directly in CSS:

@import "tailwindcss";

@plugin "tailwindcss-smooth-corners" {
  default: 2.8;
}

Theme Configuration

You can also define reusable shape tokens in tailwind.config.ts:

export default {
  theme: {
    extend: {
      cornerShape: {
        DEFAULT: 2.4,
        squircle: 2,
        soft: 4,
      },
    },
  },
};

Then use them with utilities like:

<div class="rounded-2xl corner-shape-squircle"></div>
<div class="rounded-2xl corner-shape-soft"></div>

Per-Element Overrides

If you only want to change the shape on one element, use corner-shape-* utilities.

Named values

<div class="rounded-[28px] corner-shape-soft"></div>

Numeric values

<div class="rounded-[28px] corner-shape-3"></div>

Arbitrary values

<div class="rounded-[28px] corner-shape-[superellipse(1.6)]"></div>

Reset back to normal rounded corners

<div class="rounded-[28px] corner-shape-round"></div>

Reset back to the configured default

<div class="rounded-[28px] corner-shape-default"></div>

Works With Arbitrary Radius Values

This plugin also supports Tailwind's arbitrary radius utilities:

<div class="rounded-[20px]"></div>
<div class="rounded-t-[32px]"></div>
<div class="rounded-bl-[48px]"></div>

Browser Support

The plugin outputs corner-shape inside:

@supports (corner-shape: round)

So:

  • supported browsers get smooth corners
  • unsupported browsers fall back to normal Tailwind rounded corners

Requirements

  • Tailwind CSS v4

This package is built for Tailwind's CSS-first plugin workflow.

Common Example

@import "tailwindcss";
@plugin "tailwindcss-smooth-corners";
<div class="rounded-3xl bg-white p-6 shadow-sm">
  Smooth card
</div>

<button class="rounded-full bg-black px-4 py-2 text-white">
  Smooth pill button
</button>

Development

From the monorepo root:

pnpm --filter tailwindcss-smooth-corners test
pnpm --filter tailwindcss-smooth-corners build

License

MIT