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

solid-spinner

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

solid-spinner

Pure SVG loading spinners for SolidJS

  • 0.1.6
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
936
increased by35.46%
Maintainers
1
Weekly downloads
 
Created
Source

[WIP] Solid Spinner

Warning Under active development. Do not use in production.

Dependency free SolidJS adaptation of Sam Herberts SVG Loaders library.

✨ Features

  • 12 Spinners totally ready to use.
  • Customizable - receive props to extend their usefulness.
  • First class TypeScript support
  • Tree shakeable: What you take is what you get.
  • Reactivity, take advantage of SolidJS to react to changes in props.
  • Just import and declare in your JSX to work out-the-box

📦 Installation

Yarn

yarn add solid-spinner

NPM

npm install solid-spinner --save

PNPM

pnpm install solid-spinner

Usage

Import Spinner component and specify the type of spinner.

import { Spinner, SpinnerType } from 'solid-spinner';

<Spinner type={SpinnerType.puff} color="red" />;

Import individual component.

import { Puff } from 'solid-spinner';

<Puff color="red" />;

Spinners

Component NameType
AudioSpinneraudio
BallTriangleballTriangle
Barsbars
Circlescircles
Gridgrid
Heartshearts
Ovaloval
Puffpuff
Ringsrings
SpinningCirclesspinningCircles
TailSpintailSpin
ThreeDotsthreeDots

Customizable

Each of these components should be able to accept any SVG tag presentation attributes as props.

// render the Puff loader with a stroke opacity of .125
<Spinner type={SpinnerType.puff} stroke-opacity=".125" />

// render the Puff loader with a stroke of mint green
<Puff stroke="#98ff98" />

// render the Puff loader with a stroke of mint green and a stroke opactiy of .125
<Puff stroke="#98ff98" stroke-opacity=".125"/>

Keywords

FAQs

Package last updated on 17 Dec 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