New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@statoscope/stats-extension-compressed

Package Overview
Dependencies
Maintainers
1
Versions
22
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@statoscope/stats-extension-compressed - npm Package Compare versions

Comparing version 5.28.0 to 5.28.1

2

dist/api.d.ts
import { APIFactory } from '@statoscope/extensions';
import { Format, Size } from './generator';
export declare type API = (compilationId: string, resourceId: string) => Size | null;
export type API = (compilationId: string, resourceId: string) => Size | null;
declare const makeAPI: APIFactory<Format, API>;
export default makeAPI;

@@ -5,7 +5,7 @@ /// <reference types="node" />

import { Extension, ExtensionDescriptor } from '@statoscope/stats/spec/extension';
export declare type Compressor = string | {
export type Compressor = string | {
name: string;
version: string;
};
export declare type Size = {
export type Size = {
compressor?: Compressor;

@@ -15,20 +15,20 @@ size: number;

};
export declare type CompressFunction<TOptions = any> = (source: Buffer | string, filename: string, options?: TOptions) => Size;
export declare type Format = Extension<Payload>;
export declare type Resource = {
export type CompressFunction<TOptions = any> = (source: Buffer | string, filename: string, options?: TOptions) => Size;
export type Format = Extension<Payload>;
export type Resource = {
id: string;
size: Size;
};
export declare type Compilation = {
export type Compilation = {
id: string;
resources: Array<Resource>;
};
export declare type Payload = {
export type Payload = {
compilations: Array<Compilation>;
};
export declare type ResolvedCompressor = {
export type ResolvedCompressor = {
compressor: CompressFunction<unknown>;
params?: unknown;
};
export declare type CompressorOrPreset = string | ['gzip', ZlibOptions?] | CompressFunction;
export type CompressorOrPreset = string | ['gzip', ZlibOptions?] | CompressFunction;
export default class Generator {

@@ -35,0 +35,0 @@ private adapter?;

@@ -37,2 +37,3 @@ "use strict";

this.resolveCompilation = (0, entity_resolver_1.default)(this.payload.compilations, (item) => item.id, null, false);
this.descriptor.adapter = this.adapter;
}

@@ -39,0 +40,0 @@ handleResource(compilationId, resourceId, source, compressor) {

{
"name": "@statoscope/stats-extension-compressed",
"version": "5.28.0",
"version": "5.28.1",
"description": "Statoscope extension for collecting compressed resource sizes",
"main": "./dist/index.js",
"scripts": {
"build": "../../node_modules/.bin/tsc",
"prepublishOnly": "npm run build"
"build": "../../node_modules/.bin/tsc"
},

@@ -21,10 +20,8 @@ "repository": "https://github.com/statoscope/statoscope.git",

"dependencies": {
"@statoscope/helpers": "5.28.0",
"@statoscope/extensions": "5.28.1",
"@statoscope/helpers": "5.28.1",
"@statoscope/stats": "5.28.1",
"gzip-size": "^6.0.0"
},
"devDependencies": {
"@statoscope/extensions": "5.14.1",
"@statoscope/stats": "5.14.1"
},
"gitHead": "8593d1728fba7201855ba496eb5c01d28333c60b"
"gitHead": "a89f68a6251a1c914791e22b643dd94ca2a70253"
}
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