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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@inb/oeb-messages

v1.0.0

Published

A messages component for OEB web ecosystem

Readme

OEB messages

OEB Messages is a lightweight Web Component that displays customizable messages fetched from a remote JSON file. It's designed for the OpenEBench web ecosystem but can be used anywhere.

🚀 Installation

You can use the component in three different ways:

📦 Option 1: Via NPM

npm install @inb/oeb-messages
import oeb-messages from 'oeb-messages':

Requires Node.js ≥ 18.x (recommended: 20.x)

🌐 Option 2: Via CDN

<script src="https://cdn.jsdelivr.net/gh/inab/oeb-messages@main/dist/oeb-messages.umd.js"></script>

Just import CustomMessage.js file in your component

🧩 Option 3: Direct JS Module

import CustomMessage from './CustomMessage.js';

💡 Basic Usage

Add the component to your HTML:

<custom-message url="https://example.com/message.json"></custom-message>

🎨 Custom Styling

You can customize the visual appearance using HTML attributes:

<custom-message 
  url="https://example.com/message.json"
  borderColor="lightsteelblue"
  backgroundColor="azure"
  textColor="gray">
</custom-message>

📄 Expected JSON Format

The external JSON file must follow this structure:

{
  "isActive": true,
  "start_date": "2025-08-05",
  "end_date": "2025-08-07",
  "start_show": "2025-08-01",
  "end_show": "2025-08-07",
  "icon": "<svg>...</svg>",
  "message": "Maintenance from <b>##end_month ##start_date</b> to <b>##end_date</b>."
}
Notes:
  • start_show and end_show are optional — if omitted, the message will only display if isActive is true.

  • Tokens like ##start_date, ##end_date, and ##end_month will be dynamically replaced.

  • All date comparisons are done in UTC.

🧪 Example (with GitHub raw JSON)

<script type="module" src="https://cdn.jsdelivr.net/gh/inab/oeb-messages@main/dist/oeb-messages.umd.js"></script>

<custom-message
  url="https://raw.githubusercontent.com/inab/oeb-messages/main/demo/message-advanced.json"
  backgroundColor="#f0f8ff"
  borderColor="#1e90ff"
  textColor="#000">
</custom-message>

🛠 Local Development

npm install
npm run dev       # Run Vite dev server
npm run build     # Build the final bundle into /dist

📝 License

---
Let me know if you want this saved directly as a file, or want it committed to your repo.