Skip to main content

JavaScript minifier. PLEASE UPDATE TO VERSION >= 2.0.6. Older versions have a serious bug related to comments.

Project description

JavaScript minifier.

Usage

from jsmin import jsmin
with open('myfile.js') as js_file:
    minified = jsmin(js_file.read())

You can run it as a commandline tool also:

python -m jsmin myfile.js

Where to get it

Contributing

Issues and Pull requests will be gratefully received on Bitbucket. Pull requests on github are great too, but the issue tracker lives on bitbucket.

If possible, please make separate pull requests for tests and for code: tests will be committed on the stable branch (which tracks the latest released version) while code will go to default by, erm, default.

Unless you request otherwise, your Bitbucket identity will be added to the contributor’s list below; if you prefer a different name feel free to add it in your pull request instead. (If you prefer not to be mentioned you’ll have to let the maintainer know somehow.)

Build/test status

Both default and stable branches are tested with Travis: https://travis-ci.org/tikitu/jsmin

Stable (latest released version plus any new tests) is tested against CPython 2.6, 2.7, 3.2, and 3.3. Currently:

https://travis-ci.org/tikitu/jsmin.png?branch=ghstable

If stable is failing that means there’s a new test that fails on the latest released version on pypi, with no fix yet released.

Default (development version, might be ahead of latest released version) is tested against CPython 2.6, 2.7, 3.2, and 3.3. Currently:

https://travis-ci.org/tikitu/jsmin.png?branch=master

If default is failing don’t use it, but as long as stable is passing the pypi release should be ok.

Contributors (chronological commit order)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

jsmin-2.0.11.tar.gz (8.2 kB view details)

Uploaded Source

File details

Details for the file jsmin-2.0.11.tar.gz.

File metadata

  • Download URL: jsmin-2.0.11.tar.gz
  • Upload date:
  • Size: 8.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for jsmin-2.0.11.tar.gz
Algorithm Hash digest
SHA256 7898a19e17a89b1e294cce4a43b107441630eeacae4cf9595961eb39e1a716d1
MD5 dc0cebc0cd488238b3e92b64c7d54abf
BLAKE2b-256 329c24565b0690d5aec20e5d1d1721f4b1b647d51b9326d7e73a3b32d572c9d0

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page