is-unicode-supported (0.1.0)
Published 2026-02-24 13:58:43 +00:00 by atheaadmin
Installation
registry=npm install is-unicode-supported@0.1.0"is-unicode-supported": "0.1.0"About this package
is-unicode-supported
Detect whether the terminal supports Unicode
This can be useful to decide whether to use Unicode characters or fallback ASCII characters in command-line output.
Note that the check is quite naive. It just assumes all non-Windows terminals support Unicode and hard-codes which Windows terminals that do support Unicode. However, I have been using this logic in some popular packages for years without problems.
Install
$ npm install is-unicode-supported
Usage
const isUnicodeSupported = require('is-unicode-supported');
isUnicodeSupported();
//=> true
API
isUnicodeSupported()
Returns a boolean for whether the terminal supports Unicode.
Related
- is-interactive - Check if stdout or stderr is interactive
- supports-color - Detect whether a terminal supports color
- figures - Unicode symbols with Windows fallbacks
- log-symbols - Colored symbols for various log levels
Dependencies
Development Dependencies
| ID | Version |
|---|---|
| ava | ^2.4.0 |
| tsd | ^0.14.0 |
| xo | ^0.38.2 |
Keywords
terminal
unicode
detect
utf8
console
shell
support
supports
supported
check
detection