New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

irc-caret-notation

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

irc-caret-notation

Caret notation parser for IRC

  • 1.0.5
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

IRC Caret Notation

This is a module for parsing the IRC text formatting syntax into structures you can use to render it in your engine of choice. I have made a similar library in the past, but it has a different API that I did not want to completely break compatibility with.

Versions 1.0.2 through 1.0.5 is just fixing audit warnings for dev dependencies. That makes zero diffence for dependents.

const {parse} = require("irc-caret-notation");

const chunks = parse("This is a \x02bold statement\x02.");

console.log(chunks);
/*
[ Chunk {
    bold: false,
    italic: false,
    underline: false,
    fg: null,
    bg: null,
    text: 'This is a ' },
  Chunk {
    bold: true,
    italic: false,
    underline: false,
    fg: null,
    bg: null,
    text: 'bold statement' },
  Chunk {
    bold: false,
    italic: false,
    underline: false,
    fg: null,
    bg: null,
    text: '.' } ]
*/

The chunks has a few helper methods for HTML-based rendering: methods to generate CSS classes and html-safe text with leading/trailing spaces turned into  .

Keywords

FAQs

Package last updated on 14 Jan 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc