Coder Social home page Coder Social logo

payment-icons's Introduction

npm version Build Status

Payment-icons

Payment related svg icons for use in fonts or spritesheets.

Usage

The raw .svg output (from a mix of sketch and inkscape) is in the svg directory. The minified svg output is in the min dir.

The easiest way to consume these icons is to npm install from github and use your favorite toolchain to build fonts or sprites e.g.

yarn add payment-icons

or

npm install payment-icons

How to use in something like react?

You'll need to use the svg like you do any other image asset. Exactly how will depend on what you're using in your build process.

If you're using webpack for example, then as long as your loader config understands svg you can import like you would with any other image. Here's an example for doing that (this is from create-react-app which uses webpack)

Doing it that way you'll need to find the path from node_modules/payment-icons/ so if you're looking for the flat visa icon that should be something like this:

import visa from 'payment-icons/min/flat/visa.svg';

Icon Demo

Examples generated with svg-sprite can be seen here: http://muffinresear.ch/payment-icons/

Contributing icons

If you want to remix these icons, have at it. If you have additional icons you want to be included then please follow the examples given and add your icon for each of the existing styles and make a pull request.

CLI

Note: This CLI is only relevant for development or maintenance purposes.

  • yarn run build - creates minified SVG.
  • yarn run publish - builds the sprite and publishes it to github pages.

License

Icon marks are copyright their respective owners.

The rest of the code here is MPL2.0.

payment-icons's People

Contributors

dependabot[bot] avatar greenkeeper[bot] avatar lkay avatar longmd avatar marcospaiva avatar muffinresearch avatar paulradzkov avatar renovate-bot avatar solidlink avatar tinogomes avatar wolfadex avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.