UNPKG

469 BMarkdownView Raw
1Deprecated. Just use `String#codePointAt()`.
2
3---
4
5# code-point-at
6
7> ES2015 [`String#codePointAt()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/codePointAt) [ponyfill](https://ponyfill.com)
8
9
10## Install
11
12```
13$ npm install --save code-point-at
14```
15
16
17## Usage
18
19```js
20var codePointAt = require('code-point-at');
21
22codePointAt('🐴');
23//=> 128052
24
25codePointAt('abc', 2);
26//=> 99
27```
28
29## API
30
31### codePointAt(input, [position])