ghicons
v0.2.0
Published
Ghanaian symbols — optimised SVGs and a machine-readable registry. Adinkra, currency, national emblems and more. Framework-agnostic, zero dependencies.
Maintainers
Readme
ghicons 🇬🇭
Ghanaian symbols — optimised SVGs and a machine-readable registry.
Adinkra and other tribal symbols, the currency, national emblems and more, as plain SVG files with no dependencies and no framework. Gathered in one place and standardised so every symbol behaves the same. Use them with anything: Vue, Svelte, Angular, Astro, Django, Laravel, WordPress, plain HTML, or your own tooling.
Building with React? Install @ghicons/react instead — it wraps these same icons as typed components.
⚠️
ghiconsused to be the React package. As of0.1.0this name is the framework-agnostic core and React moved to@ghicons/react. See the migration guide.
Install
npm install ghiconsWhat's in the box
ghicons/
├── svg/
│ ├── adinkra/GyeNyame.svg …and 100+ more
│ ├── general/
│ └── national/
├── registry.json the index of the whole collection
└── index.js / index.cjs convenience accessorsUse the SVG files
<img src="node_modules/ghicons/svg/adinkra/GyeNyame.svg" alt="Gye Nyame">Paths are stable, so a build step can copy them reliably.
Every icon is drawn on a 0 0 24 24 canvas and uses fill="currentColor". Inline the SVG if you want CSS to control its colour — an <img> cannot inherit colour from the page:
.icon { color: #b8860b; }Use the registry
import { icons, categories, getIcon, iconsByCategory } from 'ghicons';
getIcon('gye-nyame');
// { name: 'GyeNyame', slug: 'gye-nyame', category: 'adinkra',
// viewBox: '0 0 24 24', file: 'svg/adinkra/GyeNyame.svg' }
iconsByCategory('national'); // [BlackStar, GhanaFlag]
categories; // ['adinkra', 'general', 'national']CommonJS works too:
const { icons } = require('ghicons');Or read the JSON directly, from any language:
import registry from 'ghicons/registry.json';Use it to build an icon picker, a search interface, a docs page, or your own code generator.
Registry fields
| Field | Always present | Description |
|---|:---:|---|
| name | ✅ | PascalCase name, and the identifier framework packages use |
| slug | ✅ | Kebab-case identifier, stable across every channel |
| category | ✅ | adinkra, general, national, … |
| viewBox | ✅ | Always 0 0 24 24 |
| file | ✅ | Path to the SVG inside this package |
| meaning | | Documented meaning, where researched |
| note | | Longer context: origin, variations, or a contested reading |
| keywords | | Search keywords |
| aliases | | Alternate and vernacular names |
| references | | Where the meaning came from. Present wherever a meaning is |
The index itself carries version, count and categories alongside icons.
Every icon carries a meaning, keywords and the references the meaning was
taken from; most also carry a note and the alternate spellings people search
for. These are cultural symbols, so a meaning ships only once it is sourced —
corrections and better sources are always welcome, and the standards they are
held to are in the
cultural guidelines.
Why this package exists
The SVG collection is GHIcons' source of truth — every framework package is generated from it. This package ships that collection directly, so the framework you use never decides whether Ghanaian visual language is available to you.
Links
License
MIT © Methuselah Nwodobeh
