Loading

The Loading component provides customizable animated loading indicators including SVG, EpicSpinners, and a simple fallback.

Overview

The Loading component is a versatile and customizable loading indicator that supports multiple animation types. It helps you indicate loading states within your application and can be easily styled and configured to fit your design system.

Basic Usage

To use a loading spinner, simply provide the type prop with a loader name:

<Loading />

Type

Defines the name of the loading animation to use.

If the provided type matches a known Epic or SVG loader, it will render accordingly. Otherwise, it will fallback to the default "simple" loader.

Animation Duration

Specifies how long the animation cycle lasts in milliseconds. Adjust this to speed up or slow down the animation.

  • Type: number — typically one of: 1000, 1200, ...
  • Default: Depends on the loader type.
300ms
500ms
1000ms
2000ms
5000ms
9000ms
<Loading type="dot-revolve" :animationDuration="2000" />

This example slows the animation to 2 seconds per cycle.

Size

Sets the size of the loader in pixels.

  • Type: number — commonly: 40, 50, 55, 60, 64, 65, 66, 70

This size is applied to both width and height.

25px
30px
40px
50px
60px
<Loading type="circular" :size="50" />

This will render the loader with a width and height of 50px.

Color

Defines the color of the loader animation. Accepts any valid CSS color string.

red
green
blue
yellow
pink
purple
<Loading type="circular" color="#4F46E5" />

This will render the spinner in indigo.

Class

Allows you to apply custom CSS classes to the loader container for layout and styling purposes.

<Loading type="line-scale" class="custom-class" />

Fallback Behavior

If the specified type is not recognized in either EpicSpinners or SVG Loaders, the component will:

  • Log a warning to the console.
  • Fallback to the default "simple" loader.
<Loading type="unknown-loader" />

Complete List of Available Loaders

You can find the full list of available loaders here:

EpicSpinners

A collection of customizable animated spinners written in pure CSS.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
SVG Loaders

A set of lightweight SVG-based loading animations.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
© 2025 FishtVue by Egoka