Skip to content

tsmean/spinner

Repository files navigation

@tsmean/spinner

A library to display loading spinners, working seamlessly with Angular 2, 4, 5 and 6. (http://spinner.tsmean.com)

Build Status License npm Support

Table of contents

Demo

Working Demo

or edit directly on Stackblitz:

https://stackblitz.com/edit/tsmean-spinner

Installation

@tsmean/spinner is available via npm.

Using npm:

$ npm install @tsmean/spinner

Using yarn:

$ yarn add @tsmean/spinner

Usage

Import SpinnerModule in in the root module(AppModule):

// Import library module
import { SpinnerModule } from '@tsmean/spinner';

@NgModule({
  imports: [
    // ...
    SpinnerModule.forRoot({
      primaryColor: '#ff0000',
      secondaryColor: '#00ff00',
      animation: 'spin 1.5s cubic-bezier(0.68, -0.55, 0.265, 1.55) infinite'
    })
  ]
})
export class AppModule { }

Then use the spinner either in block format

<spinner color="primary"></spinner>

or inline

<spinner [display]="inline"></spinner>

There are many options more to customize the spinner, for a full reference please visit http://spinner.tsmean.com/.

Browser Support

Chrome IE 10+ Edge Safari Firefox Opera

Also working on mobile devices (Android and iOS).

Versioning

@tsmean/spinner is maintained with the Semantic Versioning guidelines. Releases will be numbered with the following format:

<major>.<minor>.<patch>

For more information on SemVer, please visit http://semver.org.

Contributing

If you're a developer and you'd like to contribute, your go-to readme is the README.dev.md.

License

The MIT License (MIT)