Socket
Socket
Sign inDemoInstall

resource-loader

Package Overview
Dependencies
2
Maintainers
1
Versions
57
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.5.0 to 1.5.1

2

package.json
{
"name": "resource-loader",
"version": "1.5.0",
"version": "1.5.1",
"main": "./src/index.js",

@@ -5,0 +5,0 @@ "description": "A generic asset loader, made with web games in mind.",

@@ -428,3 +428,3 @@ var EventEmitter = require('eventemitter3'),

Resource.prototype._onProgress = function (event) {
if (event.lengthComputable) {
if (event && event.lengthComputable) {
this.emit('progress', this, event.loaded / event.total);

@@ -707,3 +707,3 @@ }

* @static
* @param extname {string} The extension to set the type for, e.g. ".png" or ".fnt"
* @param extname {string} The extension to set the type for, e.g. "png" or "fnt"
* @param loadType {Resource.LOAD_TYPE} The load type to set it to.

@@ -715,2 +715,9 @@ */

/**
* Sets the load type to be used for a specific extension.
*
* @static
* @param extname {string} The extension to set the type for, e.g. "png" or "fnt"
* @param xhrType {Resource.XHR_RESPONSE_TYPE} The xhr type to set it to.
*/
Resource.setExtensionXhrType = function (extname, xhrType) {

@@ -717,0 +724,0 @@ setExtMap(Resource._xhrTypeMap, extname, xhrType);

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc