Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@pixi/utils

Package Overview
Dependencies
Maintainers
3
Versions
119
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pixi/utils

Collection of utilities used by PixiJS

  • 5.0.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
108K
decreased by-15.31%
Maintainers
3
Weekly downloads
 
Created

What is @pixi/utils?

@pixi/utils is a utility library that provides a collection of helper functions and classes to assist with common tasks in the PixiJS ecosystem. It includes utilities for data structures, math operations, string manipulations, and more.

What are @pixi/utils's main functionalities?

EventEmitter

The EventEmitter class provides a way to handle custom events. You can create an instance, register event listeners, and emit events.

const { EventEmitter } = require('@pixi/utils');
const emitter = new EventEmitter();
emitter.on('event', () => console.log('Event triggered!'));
emitter.emit('event');

isMobile

The isMobile utility helps to detect if the user is on a mobile device. It provides properties to check for various mobile platforms.

const { isMobile } = require('@pixi/utils');
console.log(isMobile.any); // true if the user is on a mobile device

uid

The uid function generates a unique identifier, which can be useful for creating unique keys or IDs.

const { uid } = require('@pixi/utils');
console.log(uid()); // Generates a unique identifier

deprecation

The deprecation function logs a deprecation warning to the console, which is useful for informing developers about deprecated methods or features.

const { deprecation } = require('@pixi/utils');
deprecation('1.0.0', 'This method is deprecated, use newMethod instead.');

Other packages similar to @pixi/utils

FAQs

Package last updated on 30 Apr 2019

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

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc