npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

devicon-mithril

v1.1.3

Published

Devicon SVG icons as Mithril.js components

Downloads

758

Readme

devicon-mithril

Devicon SVG icons as Mithril.js components. Based on the same build approach as lucide-mithril.

Install

bun add devicon-mithril
# or
npm install devicon-mithril

Usage

Each component corresponds to a devicon name + variant, prefixed with Dev and converted to PascalCase.

import m from 'mithril'
import { DevJavascriptOriginal, DevReactOriginal, DevVuejsOriginal } from 'devicon-mithril'

// Basic usage — renders at the default 128×128 size
m(DevJavascriptOriginal)

// Custom size (icons are square)
m(DevReactOriginal, { size: 64 })

// Any additional SVG attributes are passed through
m(DevVuejsOriginal, { size: 48, class: 'my-icon' })

Component naming

| Devicon name | Component name | |-------------------------------|-----------------------------------| | javascript-original | DevJavascriptOriginal | | javascript-plain | DevJavascriptPlain | | react-original | DevReactOriginal | | react-original-wordmark | DevReactOriginalWordmark | | vuejs-original | DevVuejsOriginal | | adonisjs-original-wordmark | DevAdonisjsOriginalWordmark |

All 1877 icons from devicon are available (578 technologies × multiple variants).

Variants

| Variant | Description | |---------------------|--------------------------------------| | original | Full-color original icon | | plain | Simplified/monochrome version | | line | Line/outline version | | original-wordmark | Original icon with technology name | | plain-wordmark | Plain icon with technology name | | line-wordmark | Line icon with technology name |

mithril-lynx (Lynx)

mithril-lynx does not support m.trust. On Lynx, SVG must follow the native <svg> contract: content is a full <svg>...</svg> document string, and display size is set on the outer element via a style object ({ width: "Npx", height: "Npx" }), not CSS text strings.

Use the parallel icons-lynx/ components (built with lynxIcon in lynx_svg.js):

import m from 'mithril-runtime'
import DevJavascriptOriginal from 'devicon-mithril/icons-lynx/DevJavascriptOriginal.js'

const MyComponent = {
  view: () => m('view', [
    m(DevJavascriptOriginal, { size: 48 }),
  ]),
}

The web entry (devicon-mithril / icons/*) is unchanged and still uses m.trust.

mithril-runtime is an optional peer dependency: install it when you use icons-lynx/*.

Build

To regenerate the components from the latest version of devicon:

bun run build

The build script reads SVGs directly from the devicon npm package (node_modules/devicon/icons/), so no manual cloning is needed.

This will:

  1. Read all SVGs from node_modules/devicon/icons/
  2. Generate one component file per icon under icons/ (web, m.trust)
  3. Generate parallel components under icons-lynx/ (mithril-lynx, full SVG in content + size via style)
  4. Write the index.js entry point and index.d.ts TypeScript declarations

Project structure

devicon-mithril/
├── build/
│   └── build.js          # Build script
├── icons/                # Generated web icon components (1877 files)
│   ├── DevJavascriptOriginal.js
│   ├── DevReactOriginal.js
│   └── ...
├── icons-lynx/           # Generated mithril-lynx icon components
│   ├── DevJavascriptOriginal.js
│   ├── DevReactOriginal.js
│   └── ...
├── test/
│   └── index.html        # Usage example
├── default_attrs.js      # Default SVG attributes (size, viewBox)
├── default_attrs.d.ts    # TypeScript types for default_attrs
├── lynx_svg.js           # Lynx SVG helper (full content + style size)
├── lynx_svg.d.ts
├── index.js              # Generated entry point (all exports)
└── index.d.ts            # Generated TypeScript declarations

License

MIT — icon SVG data is sourced from devicon (MIT).