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

butternut

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

butternut - npm Package Versions

2

0.4.6

Diff

Changelog

Source

0.4.6

  • Too many fixes to list individually!
rich_harris
published 0.4.5 •

Changelog

Source

0.4.5

  • Remove unused function expression IDs (#98)
  • Rewrite Infinity as 1/0 (#99)
  • Remove parentheses from new expression without parameters (#100)
  • Remove leading zero from numbers, use e notation where appropriate (#102)
  • Fix order of edits around if statements (#109, #115, #117)
  • Preserve initialisers of unused variables if they may contain side-effects (#101)
rich_harris
published 0.4.4 •

Changelog

Source

0.4.4

  • Dozens of minor fixes (#91)
  • Prevent shadowing of non-aliased variables (#94)
  • Minify static class methods (#88)
  • Handle empty else blocks in if statements (#89)
  • Prevent a=a!==false becoming a!===!1 (#93)
rich_harris
published 0.4.3 •

Changelog

Source

0.4.3

  • Don't insert semicolons before else keywords that follow blocks, try statements or empty statements (#82)
  • More informative CLI error messages if repro is generated (#82)
rich_harris
published 0.4.2 •

Changelog

Source

0.4.2

  • Hoist var declarations out of removed blocks (#51)
  • More conservative constant folding (#74)
  • Allow reserved words (#79)
  • Preserve/insert parens around object literals as necessary (#77)
rich_harris
published 0.4.1 •

Changelog

Source

0.4.1

  • Remove certain side-effect-free statements (#27)
  • More efficient mangling (#55)
  • Fold constants in template literals (#62)
  • Fold array method calls in some cases (#67)
  • Remove redundant 'use strict' pragmas (#64)
  • Prevent over-eager folding of binary/logical expressions (#75)
  • Remove empty blocks (#70)
rich_harris
published 0.4.0 •

Changelog

Source

0.4.0

  • Disallow direct eval calls by default, and deopt if explicitly allowed (#31)
  • Fold exponentiation expressions (#50)
  • Remove code correctly from LogicalExpression nodes if neft hand side is truthy (#54)
  • Handle blocks with leading empty statements (#57)
  • Insert space before returned arrow function with single parameter (#52)
rich_harris
published 0.3.6 •

Changelog

Source

0.3.6

  • Correctly minify async and generator functions and methods (#43)
  • Only create scope for loops that declare variables in head (#46)
  • Remove curly braces around else-block in if-statement with falsy condition (#41)
  • Handle duplicate variables in sibling loops (#33)
  • Minify expressions in template literals (#34)
  • Handle loops with empty bodies (#38)
rich_harris
published 0.3.5 •

Changelog

Source

0.3.5

  • Remove unused class declarations (#25)
  • Remove surplus whitespace around method arguments (#23)
  • Insert space after typeof where necessary (#24](https://github.com/Rich-Harris/butternut/issues/24))
  • Handle anonymous function as default export (#28)
rich_harris
published 0.3.4 •

Changelog

Source

0.3.4

  • Remove ID of shadowed function expressions (#18)
  • Correctly separate SwitchCase consequent statements (#19)
  • Remove whitespace around NewExpression arguments (#16)
2
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