Skip to content

groteck/iconsToElm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

iconsToElm

This CLI tool creates an Assets.elm file from a directory with svg files.

Install

yarn add icons-to-elm

Use the cli

Generates a Assets.elm file in the current path:

yarn run iconsToElm svgDir

Generates a Assets.elm file in the specified path (src):

yarn run iconsToElm svgDir src

Use it on your elm project

  1. Install rnons/elm-svg-parser: elm-package install -y rnons/elm-svg-parser
  2. Import the Assets module into your elm file and call one icon.
module Main exposing (..)

import Assets
import Html exposing (Html)


main : Html msg
main =
    Assets.iconExample

NOTE: You can check the example directory for extra help.

Icons

The icons used to test the SVG transformation are licensed under GPL / CC BY 4.0

You can get and check to get more information. icomoon

About

svg directory to Elm module generator

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages