source:
frontend/node_modules/es-to-primitive/helpers/isPrimitive.js
| Last change on this file was 9af201e, checked in by , 2 weeks ago | |
|---|---|
|
|
| File size: 258 bytes | |
| Line | |
|---|---|
| 1 | 'use strict'; |
| 2 | |
| 3 | /** @type {(value: unknown) => value is null | undefined | string | symbol | number | boolean | bigint} */ |
| 4 | module.exports = function isPrimitive(value) { |
| 5 | return value === null || (typeof value !== 'function' && typeof value !== 'object'); |
| 6 | }; |
Note:
See TracBrowser
for help on using the repository browser.
