Skip to content

Commit

Permalink
docs: add go optional parsers
Browse files Browse the repository at this point in the history
  • Loading branch information
mrf345 committed Oct 22, 2023
1 parent 7dd0df1 commit c50b537
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,11 @@ With **pip**

- `pip install Flask-Minify`

*Or* from the source
for better performance (~2x) you can use the optional [go dependency](https://pypi.org/project/tdewolff-minify/)

- `pip install Flask-Minify[go]`

With **setup-tools**

- `git clone https://github.com/mrf345/flask_minify.git`
- `cd flask_minify`
Expand Down Expand Up @@ -79,6 +83,7 @@ Option | type | Description
static | `bool` | enable minifying static files css, less and js (default: `True`)
script_types | `list` | script types to limit js minification to (default: `[]`)
parsers | `dict` | parsers to handle minifying specific tags, mainly for advanced customization (default: `{}`)
go | `bool` | prefer go minifier, if optional go dependency is installed (default: `True`)


#### - `bypass` and `bypass_caching`
Expand Down Expand Up @@ -149,6 +154,9 @@ the **default** parsers are set to `{"html": Html, "script": Jsmin, "style": Rcs

## Breaking changes

#### `0.43`
Introduced more performant parsers that will be enabled by default, if the optional `Go` dependency is installed [tdewolff-minify](https://pypi.org/project/tdewolff-minify/). You can disable that behavior using `minify(go=False)`.

#### `0.40`

Due to a future deprecation in Flask 2.3, the extension is no longer going to fallback to `Flask._app_ctx_stack`, it will raise an exception instead (`flask_minify.exceptions.MissingApp`)
Expand Down

0 comments on commit c50b537

Please sign in to comment.