Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

suport minify option in filter using jstransformer #3084

Merged
merged 3 commits into from
May 1, 2020

Conversation

pirxpilot
Copy link
Contributor

@pirxpilot pirxpilot commented Dec 18, 2018

There are several advantages of that approach:

  • the code is simpler - no need to worry about specifics of minimizing
  • makes replacing the minimizers - if we ever need to do that - trivial
  • pug does not have to worry about keeping its dependencies on uglify-js and clean-css current
  • users who want to use alternative minimizers do not bear the cost of installing uglify-js and clean-css

The only drawback I can think of is that it requires pug users to explicitly install jstransformer-uglify-js or/and jstransformer-clean-css if they want to use minify option.

that removes direct dependency on uglify-js and clean-css
Copy link
Member

@ForbesLindesay ForbesLindesay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will need a major release, but I see no reason not to go ahead with it.

@rollingversions
Copy link

rollingversions bot commented May 1, 2020

pug (2.0.4 → 3.0.0)

Breaking Changes

  • The minify option on filters now requires you to install the relevant jstransformer

    Currently we support:

    • jstransformer-uglify-js for JavaScript
    • jstransformer-clean-css for CSS

pug-filters (3.1.1 → 4.0.0)

Breaking Changes

  • The minify option on filters now requires you to install the relevant jstransformer

    Currently we support:

    • jstransformer-uglify-js for JavaScript
    • jstransformer-clean-css for CSS

Packages With No Changes

The following packages have no user facing changes, so won't be released:

  • pug-attrs
  • pug-code-gen
  • pug-error
  • pug-lexer
  • pug-linker
  • pug-load
  • pug-monorepo
  • pug-parser
  • pug-runtime
  • pug-strip-comments
  • pug-walk

Edit changelogs

@ForbesLindesay ForbesLindesay merged commit a941dec into pugjs:master May 1, 2020
@ForbesLindesay ForbesLindesay mentioned this pull request May 24, 2020
@pirxpilot pirxpilot deleted the minify-with-jstransformer branch June 8, 2020 14:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants