SkillAgentSearch skills...

Writegeez

Web based Input Method Editor(IME) for Geez alphabets

Install / Use

/learn @ibra-sk/Writegeez
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

@writegeez/ime

npm version npm downloads License: MIT

A modern Web Input Method Editor (IME) for typing Geʽez-script languages such as Tigrinya, Amharic, and Tigre — built for the web, open source, and written in TypeScript.


✨ Features

  • 🪶 Lightweight – pure TypeScript, no framework dependencies.
  • ⚙️ Works anywhere – supports <input>, <textarea>, and contenteditable elements.
  • 🧠 Smart transliteration – converts Latin input to Geʽez script in real time.
  • 💻 Framework-agnostic – works with vanilla JS, React, Vue, or any frontend stack.
  • 🧩 Extensible design – customize mappings, or build your own input method spec.
  • 💬 TypeScript ready – full typings and autocomplete out of the box.

🚀 Installation

npm install @writegeez/ime
# or
yarn add @writegeez/ime

🧰 Basic Usage (Vanilla JS / TS)

import { WriteGeezIME } from "@writegeez/ime";

// Define a minimal input map for demo
const inputMap = {
  h: { value: "ህ", next: { a: { value: "ሀ" } } },
  b: { value: "ብ" },
};

const inputSpec = { map: inputMap };

const textarea = document.querySelector("textarea");

// Attach IME
const ime = new WriteGeezIME(inputSpec, textarea!, { enabled: true });

// Optional: toggle
ime.disable();
ime.enable();

Try typing “h” → “a” — it should become .


⚛️ React Example

Here’s a minimal React component demo (like the one in examples/basic):

import React, { useEffect, useRef, useMemo } from "react";
import { WriteGeezIME } from "@writegeez/ime";

export function App() {
  const textareaRef = useRef<HTMLTextAreaElement>(null);

  const spec = useMemo(
    () => ({
      map: {
        h: { value: "ህ", next: { a: { value: "ሀ" } } },
        b: { value: "ብ" },
      },
    }),
    []
  );

  useEffect(() => {
    if (!textareaRef.current) return;
    new WriteGeezIME(spec, textareaRef.current, { enabled: true });
  }, [spec]);

  return (
    <div style={{ padding: 16 }}>
      <h1>@writegeez/ime demo</h1>
      <textarea ref={textareaRef} placeholder="Type 'h' then 'a' → ሀ" rows={4} />
    </div>
  );
}

📘 API Reference

class WriteGeezIME

constructor

new WriteGeezIME(
  spec: InputMethodSpec,
  element: HTMLElement,
  options?: { enabled?: boolean }
)
  • spec — defines your transliteration mapping tree.
  • element<input>, <textarea>, or contenteditable element to attach to.
  • options.enabled — whether to start active.

Methods

| Method | Description | |--------|--------------| | enable() | Enables the IME | | disable() | Disables the IME | | setEnabled(flag: boolean) | Enables or disables based on a boolean | | isEnabled(): boolean | Returns whether the IME is active | | processInput(prevChar: string, newChar: string) | Returns { output, modifiesPrev } — used for testing or custom logic |


🧩 Extending the Input Map

Define your own transliteration rules easily:

const inputMap = {
  s: { value: "ስ", next: { a: { value: "ሳ" }, e: { value: "ሴ" } } },
};

new WriteGeezIME({ map: inputMap }, element);

🧪 Development

Clone the repo and run locally:

git clone https://github.com/ibra-sk/writegeez.git
cd writegeez
npm i
npm run dev -w @writegeez/ime
npm run dev -w writegeez-example-basic

This will watch-build the IME and open the live example app.


📦 Monorepo Structure

| Package | Description | Status | |----------|--------------|--------| | @writegeez/ime | Core Input Method Engine | ✅ Published | | @writegeez/webui | (Planned) Web UI toolkit | 🚧 Coming soon | | @writegeez/sentiment | (Planned) Sentiment analysis module | 🚧 Coming soon |


🔗 Links

  • NPM → https://www.npmjs.com/package/@writegeez/ime
  • GitHub → https://github.com/ibra-sk/writegeez

📄 License

MIT © 2025 Ibrahim Kekia

Related Skills

View on GitHub
GitHub Stars11
CategoryDevelopment
Updated19d ago
Forks2

Languages

TypeScript

Security Score

75/100

Audited on Mar 12, 2026

No findings