@stdlib/string-code-point-at-cli
v0.2.2
Published
Return a Unicode code point from a string at a specified position.
Downloads
2
Readme
codePointAt
Return a Unicode code point from a string at a specified position.
Installation
To use as a general utility, install the CLI package globally
npm install -g @stdlib/string-code-point-at-cli
Usage
Usage: code-point-at [options] --pos=<index> [<string>]
Options:
-h, --help Print this message.
-V, --version Print the package version.
-b, --backward Backward iteration for low surrogates.
--pos index Position in string.
Examples
$ code-point-at --pos=2 अनुच्छेद
2369
To use as a standard stream,
$ echo -n 'अनुच्छेद' | code-point-at --pos=2
2369
See Also
@stdlib/string-code-point-at
: return a Unicode code point from a string at a specified position.@stdlib/string-from-code-point
: create a string from a sequence of Unicode code points.
Notice
This package is part of stdlib, a standard library for JavaScript and Node.js, with an emphasis on numerical and scientific computing. The library provides a collection of robust, high performance libraries for mathematics, statistics, streams, utilities, and more.
For more information on the project, filing bug reports and feature requests, and guidance on how to develop stdlib, see the main project repository.
Community
License
See LICENSE.
Copyright
Copyright © 2016-2024. The Stdlib Authors.