You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 7-8.RSVP
Socket
Socket
Sign inDemoInstall

get-symbol-description

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

get-symbol-description

Gets the description of a Symbol. Handles `Symbol()` vs `Symbol('')` properly when possible.


Version published
Weekly downloads
24M
decreased by-18.8%
Maintainers
1
Created
Weekly downloads
 

Changelog

Source

v1.0.2 - 2024-02-07

Fixed

  • [Deps] add missing get-intrinsic #3

Readme

Source

get-symbol-description Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

Gets the description of a Symbol. Handles Symbol() vs Symbol('') properly when possible.

Example

var getSymbolDescription = require('get-symbol-description');
var assert = require('assert');

assert(getSymbolDescription(Symbol()) === undefined);
assert(getSymbolDescription(Symbol('')) === ''); // or `undefined`, if in an engine that lacks name inference from concise method
assert(getSymbolDescription(Symbol('foo')) === 'foo');
assert(getSymbolDescription(Symbol.iterator) === 'Symbol.iterator');

Tests

Simply clone the repo, npm install, and run npm test

Keywords

FAQs

Package last updated on 07 Feb 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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc