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

build(deps-dev): bump lightningcss from 1.16.0 to 1.18.0 #1759

Closed
wants to merge 1 commit into from

Conversation

dependabot[bot]
Copy link

@dependabot dependabot bot commented on behalf of github Jan 5, 2023

Bumps lightningcss from 1.16.0 to 1.18.0.

Release notes

Sourced from lightningcss's releases.

v1.18.0

This release adds support for custom transform visitors written in JavaScript, which lets you extend Lightning CSS with support for custom CSS syntax extensions, perform build time transforms, and more. It also adds support for nested @container and @layer rules, implements vendor prefixing for @supports, adds support for compiling from stdin via the CLI, and reduces compile times for the Rust crate by adding feature flags.

Custom transforms

The Lightning CSS visitor API enables you to implement custom non-standard extensions to CSS, making your code easier to author while shipping standard CSS to the browser. You can implement extensions such as custom shorthand properties or additional at-rules (e.g. mixins), build time transforms (e.g. convert units, inline constants, etc.), CSS rule analysis, and much more.

The API is designed to call into JavaScript as little as possible. You provide functions for specific types of values you're interested in such as Length, Url, or specific properties or rules. Lightning CSS fully parses all CSS rules and properties (with individual type definitions!), and only calls your plugin when it visits a value type you need to transform. This granularity improves performance, and also makes it much easier to build plugins since you don't need to worry about parsing values or selectors yourself. You can return a new value from a visitor function, or even remove or replace a value with multiple values in some cases. Check out the docs for more details!

Custom transforms have a build time cost: it can be around 2x slower to compile with a JS visitor than without. That being said, it is around 6x faster than equivalent postcss plugins in my testing. While standard CSS features should continue to be implemented in Rust as part of Lightning CSS core, the plugin API can help you migrate from other tools while supporting non-standard syntax extensions you might use. We look forward to hearing your feedback!

Playground updates

The Lightning CSS playground has also been updated to support visitors, which makes it easy to play around right in your browser. It also has a new editor experience powered by Code Mirror including syntax highlighting and inline errors. Check out an example with a custom visitor to see what it can do.

New docs

The Lightning CSS website has also been updated to include documentation for all of the features, including transpilation, CSS modules, bundling, and minification.

Features

  • JavaScript visitor API for custom transforms – #363
  • Add visitor support to WASM build via napi-wasm – #373
  • Parse @container and @layer block rules nested within style rules – 615893c00386fe154c7ad33fddc116416e25b407
  • Add projectRoot option and use relative paths for CSS module hashes – 33febb4a87f40da0d9d0991ac5c886f8691fcd26
  • Implement vendor prefixing for @​supports – 787f46f7e6b673778bfc33d95cf77fad7e730220
  • CLI support for piping – #380
  • Introduce "bundler" feature flag – #358
  • Put all of serde behind feature flag – #360
  • Introduce "visitor" feature flag – #367
  • Add sourcemap feature – #372
  • Remove derive-move – #377

Fixes

  • Fix important declarations within nested at rules – 6a7d19e81234809bc3c27ac65bc14e9ee4422a2c
  • Remove parentheses from supports condition AST – 87ca70512ca5a57ae5f8cd81f890faf30f5b28ce

v1.17.1

Fixed a regression where zero lengths were serialized without a unit in custom properties, which could break calc() usages. 0afccf92d206022cd7f9f62975ed1f11354b68e2

v1.17.0

This release includes support for the new nesting syntax, a new Rust visitor API to make building custom transforms easier, support for page margin at rules, and several other improvements and fixes.

New nesting syntax

The CSS nesting support has been updated to relax some of the rules around where the & selector is required, following the latest spec changes. The & selector is now automatically inserted with a descendant combinator when not already present, unless it starts with an element selector. The @nest rule is deprecated, and will print a warning.

.foo {
</tr></table> 

... (truncated)

Commits

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [lightningcss](https://github.com/parcel-bundler/lightningcss) from 1.16.0 to 1.18.0.
- [Release notes](https://github.com/parcel-bundler/lightningcss/releases)
- [Commits](parcel-bundler/lightningcss@v1.16.0...v1.18.0)

---
updated-dependencies:
- dependency-name: lightningcss
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot @github
Copy link
Author

dependabot bot commented on behalf of github Jan 5, 2023

The following labels could not be found: dependencies.

@dependabot @github
Copy link
Author

dependabot bot commented on behalf of github Feb 14, 2023

Superseded by #1779.

@dependabot dependabot bot closed this Feb 14, 2023
@dependabot dependabot bot deleted the dependabot/npm_and_yarn/lightningcss-1.18.0 branch February 14, 2023 05:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants