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

@thetypefounders/unicode-classifier

Package Overview
Dependencies
Maintainers
0
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@thetypefounders/unicode-classifier

Classification of Unicode codepoints by Unicode categories and scripts.

  • 1.1.0
  • latest
  • npm
  • Socket score

Version published
Maintainers
0
Created
Source

Unicode Classifier

This is a TypeScript module that you can use to classify codepoints by their category and script (writing system).

Installation

npm install @thetypefounders/unicode-classifier --save

Usage

import classify from '@thetypefounders/unicode-classifier';

console.log(classify([64, 65, 66, 67]));

// { Nd: { Common: [ 48, 49, 50 ] }, Lu: { Latin: [ 65, 66, 67 ] } }

If the codepoint is not in Unicode, the classifier will sort it under the Unknown category and Unknown script:

import classify from '@thetypefounders/unicode-classifier';

console.log(classify([56845]));

// { Unknown: { Unknown: [ 56845 ] } }

Data

Codepoint categories and scripts data is automatically downloaded from the Unicode website. To update the data, change UNICODE_VERSION in src/update.ts and run npm run update to update the data file.

FAQs

Package last updated on 16 Jul 2024

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