Skewind is compatible with all svg icons libraries. We have installed some of these icon libraries, including but not limited to: feather, heroicons, dripicons, ionicons, flag-icons and flat-color-icons.

You can see and search the list of available icons here:

See all available icons

Usage

Data API

The easiest way to insert an icon onto your webpage is by using our Data API. You just have to add the data-icon="{iconName}" attribute to any element that you want.


                            

Javascript

On some occasions, you may need to use javascript to insert an icon. We have done our best to document it at the moment.

Methods

From the Icon object, you can call any of these methods initially.

Method Description
Icon.replace(wrapperElement) Basically, this method is used by the Data API to replace all data-icon="{iconName}" with the constructed svg contents by the specified icon name.
Icon.create(iconName, attrs) Create an instance of the icon with the name specified, then followed by calling toSvg(attrs). attrs is an object used to append some attributes to the output of svg code. Eg: Icon.create('feather__x').toSvg({ class: 'w-10 h-10' })