Socket
Socket
Sign inDemoInstall

sizemometer

Package Overview
Dependencies
487
Maintainers
1
Versions
24
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    sizemometer

A library for monitoring your bundle sizes


Version published
Weekly downloads
18
increased by157.14%
Maintainers
1
Install size
47.9 MB
Created
Weekly downloads
 

Readme

Source

Sizemometer

npm version Build Status

Monitoring for your front end assets. Gives you nice graphs to track the size of your files over time.

Setting up

Install the package:

npm install -S sizemometer

Set up a config file at .sizemometer/config.js in the root of your project.

module.exports = {
  title: 'Your project name',
  trackedFiles: ['dist/bundle.js', 'main-*.js'],
  commitIgnorePattern: 'Update dependency',
  theme: {
    accentColor: '#BADA55'
  },
  repositoryUrl: 'https://github.com/chardos/sizemometer'
}
PropertyDescriptionTypes
titleDisplayed in app headerstring
trackedFilesFiles to take snapshots of. Supports globbing.array
commitIgnorePatternWhen this matches your latest commit message, no new snapshot will be takenstring, regex
theme.accentColorChanges the color of the barsstring

Using sizemometer

To take your first snapshot, run:

npx sizemometer add

Then to view the report:

npx sizemometer report

API

import { add } from 'sizemometer';

await add({currentHistory});

FAQs

Last updated on 09 Aug 2019

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc