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 🙏

© 2024 – Pkg Stats / Ryan Hefner

vue-wave-skeleton

v1.0.0

Published

Cool Wave Skeleton component for loading content in Vue 3. Animated, unique, and chill.

Downloads

2

Readme

Vue Wave Skeleton

Animated skeleton component for Vue 3, by moving svg wave with constant chill animation. A cool way to show that the text content of your page is loading, an alternative to the boring, typical skeletons.

wave

Install

npm i vue-wave-skeleton

Usage

import WaveSkeleton from 'vue-wave-skeleton'

// register globally
app.component('WaveSkeleton', WaveSkeleton)

// or locally
export default {
	components: { WaveSkeleton },
	// ...
}
<!-- place the component inside the template -->
<WaveSkeleton />
/* and set the size in css */
.wave-skeleton {
	width: 260px;
	height: 30px;
}

Props

Right now there aren't a lot of these. But let me know if you need some.

transitionName

  • Optional
  • Type: String
  • Name of your cursom enter/leave transition, you want to use instead of the default fade.

CSS Variables

Some css properties can be easily changed by setting css variables.

/* the defaults: */
.gooey-background {
	/* name of the infinite animation, the default is a simple fade */
	--wave-skeleton-animation: wave-skeleton-fade;
	/* duration of the animation */
	--wave-skeleton-duration: 800ms;
	/* stroke color of the wave */
	--wave-skeleton-color: #828282;
	/* stroke width */
	--wave-skeleton-stroke-width: 5.2px;
	/* shape of the path cap */
	--wave-skeleton-stroke-linecap: round;
}

Sizes in CSS

Right now this component doesn't have a default height or width, so it's for you to decide on it yourself and set it.

The generall rule is to have matching height between components you want to have looking similar.

To add other sizes e.g. to represent titles or captions, use classes, like .title or .caption.

<WaveSkeleton class="title" /> <WaveSkeleton class="title smaller" />
.wave-skeleton.title {
	width: 280px;
	height: 50px;
}
.wave-skeleton.smaller {
	width: 130px;
}

About the effect

The original solution I've based mine is this codepen by Varun Vachhar. Also check out my prototype codepen where I've tried to adapt this solution.

Generally I've made this component to use in my personal projects. But let me know if you have any ideas / requests regarding this component. It's a really cool effect, so I would like to tur it into an even better component.