diff --git a/.github/workflows/publish-node.yml b/.github/workflows/publish-node.yml index 601a29c..7921713 100644 --- a/.github/workflows/publish-node.yml +++ b/.github/workflows/publish-node.yml @@ -13,10 +13,10 @@ on: - "*" tags: - v* + pull_request: jobs: build: - if: ${{ startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/ci' }} strategy: fail-fast: false matrix: @@ -196,8 +196,6 @@ jobs: packages/*/*.node if-no-files-found: error build-freebsd: - if: ${{ startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/ci' }} - runs-on: macos-10.15 name: Build FreeBSD steps: @@ -259,7 +257,6 @@ jobs: packages/*/*.node if-no-files-found: error test-macOS-windows-binding: - if: ${{ startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/ci' }} name: Test bindings on ${{ matrix.settings.target }} - node@${{ matrix.node }} needs: - build @@ -301,7 +298,6 @@ jobs: - name: Test bindings run: yarn workspaces run test test-linux-x64-gnu-binding: - if: ${{ startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/ci' }} name: Test bindings on Linux-x64-gnu - node@${{ matrix.node }} needs: - build @@ -340,7 +336,6 @@ jobs: - name: Test bindings run: docker run --rm -v $(pwd):/swc -w /swc node:${{ matrix.node }}-slim yarn workspaces run test test-linux-x64-musl-binding: - if: ${{ startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/ci' }} name: Test bindings on x86_64-unknown-linux-musl - node@${{ matrix.node }} needs: - build @@ -379,7 +374,6 @@ jobs: - name: Test bindings run: docker run --rm -v $(pwd):/swc -w /swc node:${{ matrix.node }}-alpine yarn workspaces run test test-linux-aarch64-gnu-binding: - if: ${{ startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/ci' }} name: Test bindings on aarch64-unknown-linux-gnu - node@${{ matrix.node }} needs: - build @@ -421,7 +415,6 @@ jobs: yarn workspaces run test ls -la test-linux-aarch64-musl-binding: - if: ${{ startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/ci' }} name: Test bindings on aarch64-unknown-linux-musl - node@${{ matrix.node }} needs: - build @@ -456,7 +449,6 @@ jobs: apk add nodejs npm yarn yarn workspaces run test test-linux-arm-gnueabihf-binding: - if: ${{ startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/ci' }} name: Test bindings on armv7-unknown-linux-gnueabihf - node@${{ matrix.node }} needs: - build diff --git a/Cargo.lock b/Cargo.lock index c338569..9ccb63c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -70,9 +70,9 @@ checksum = "8da52d66c7071e2e3fa2a1e5c6d088fec47b593032b254f5e980de8ea54454d6" [[package]] name = "ast_node" -version = "0.8.1" +version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87549fcb780f81054407f313a1693d102396c223f5c49ccc5d90b46a6cbef34a" +checksum = "cf94863c5fdfee166d0907c44e5fee970123b2b7307046d35d1e671aa93afbba" dependencies = [ "darling", "pmutil", @@ -1103,6 +1103,12 @@ dependencies = [ "url", ] +[[package]] +name = "stable_deref_trait" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" + [[package]] name = "static_assertions" version = "1.1.0" @@ -1184,22 +1190,23 @@ dependencies = [ [[package]] name = "swc_atoms" -version = "0.4.12" +version = "0.4.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11c4324b88922face9483a996a439b29614aa97ff6dfe8574572a7bde4fbadaa" +checksum = "7f18e15aaf62701ebc4aabf01746571c2ab54b91c94b81de23e435d6fb2e2567" dependencies = [ "once_cell", "rustc-hash", "serde", "string_cache", "string_cache_codegen", + "triomphe", ] [[package]] name = "swc_cached" -version = "0.3.8" +version = "0.3.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1142494d22c93a60e7389cec0e6e0c8d73f15ff502884fe4855d3068c3ea51e5" +checksum = "f371ecac3d2ca332c67f1f469711fa576755f30abf1a57b7eec7be14c8e31ce0" dependencies = [ "ahash", "anyhow", @@ -1212,9 +1219,9 @@ dependencies = [ [[package]] name = "swc_common" -version = "0.28.1" +version = "0.28.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1e7fbe2637e612ca99c49b725f3b63f13e84969e8b28848b8336da72e2b1054" +checksum = "54a4f584c7b203c555c2ef23ede09ae38456305cd28989bf5f807b93316cbc57" dependencies = [ "ahash", "ast_node", @@ -1267,9 +1274,9 @@ dependencies = [ [[package]] name = "swc_css_ast" -version = "0.112.0" +version = "0.112.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c8fc3ac7b6bdc82077a0bddaed6b0eadcd086918a5281afe744eb793df06578" +checksum = "55fde2d339ff997f18bff6c2026563d7865948daa4f8797529a8f710bec8dc5c" dependencies = [ "is-macro", "serde", @@ -1280,9 +1287,9 @@ dependencies = [ [[package]] name = "swc_css_codegen" -version = "0.122.0" +version = "0.122.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c583458d3e07ab9ac8319be1142bf4693a1c84677a62b217dbc1800738ff2b1" +checksum = "f039adf3000fa55a7dd8bce05e73fafeb445a74d0d033f90b70766968b161aa0" dependencies = [ "auto_impl", "bitflags", @@ -1309,9 +1316,9 @@ dependencies = [ [[package]] name = "swc_css_minifier" -version = "0.87.0" +version = "0.87.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "438085d884c5c2513c9d1cbddd489e09f230bfd431a0a61f55f9caabf25f338f" +checksum = "01724b1b8b7040897fae83829114b08532137090350120d105e118775bb1efee" dependencies = [ "serde", "swc_atoms", @@ -1323,9 +1330,9 @@ dependencies = [ [[package]] name = "swc_css_parser" -version = "0.121.0" +version = "0.121.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5758cd8b7f9cee92dde8495fa740045fb66231b3c552477fca3876f34088cdbd" +checksum = "1f7c009745345cec38bba2632f8924e88673794e588dfe05f1e0c9ddca624d41" dependencies = [ "bitflags", "lexical", @@ -1337,9 +1344,9 @@ dependencies = [ [[package]] name = "swc_css_utils" -version = "0.109.0" +version = "0.109.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fe647f460321a5ec22aec75edb3aac2f2d183002a0324af987db67ae9ade4dc" +checksum = "247ca5a36c86b2ccaa69f9a483a68a6f86f0f0170eadbc6a50cd3370a6208004" dependencies = [ "once_cell", "serde", @@ -1352,9 +1359,9 @@ dependencies = [ [[package]] name = "swc_css_visit" -version = "0.111.0" +version = "0.111.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcce6ed398bd0831042943be2efd44792011c66882d312306fc4967d289dfc37" +checksum = "e20e17509acb8ff89cbe47dae399cbe549335d1fea3a218cf62b48a07bb2dbf6" dependencies = [ "serde", "swc_atoms", @@ -1365,9 +1372,9 @@ dependencies = [ [[package]] name = "swc_ecma_ast" -version = "0.91.1" +version = "0.91.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fe489c6f0b9649464d1135d2fec8c1bb5cb91a7b85d6b521e68930dac062bf0" +checksum = "7df6d5ece8b32be2c4501b11d917a449d4e15a0cef935f61bd3583f277443914" dependencies = [ "bitflags", "is-macro", @@ -1382,9 +1389,9 @@ dependencies = [ [[package]] name = "swc_ecma_codegen" -version = "0.124.4" +version = "0.124.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c812ebcc5f2ef17302f424286146eee9da212d942e21ab8bdc7689821f1da9a" +checksum = "e6155f5a65fe66e4d870d8755af60de5b2a4ab1d2464da640cd56618d3bee50c" dependencies = [ "memchr", "num-bigint", @@ -1414,9 +1421,9 @@ dependencies = [ [[package]] name = "swc_ecma_minifier" -version = "0.154.7" +version = "0.154.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "caefe4025afa4a0d5063b3bf50f8c4f7d41a0c6d5bf9b318ca98aec7d3ecffb5" +checksum = "288d311dfcc8175e922bd8bed81158a297a94ae5d9762a75f5428036b9dbcc53" dependencies = [ "ahash", "arrayvec", @@ -1447,9 +1454,9 @@ dependencies = [ [[package]] name = "swc_ecma_parser" -version = "0.119.3" +version = "0.119.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c09070e408c0b2bb730f0fa413826a9743226c9a286998e367498ffb7299871f" +checksum = "f99872d1038049cb57d89ba8e4cb74b63ff95a0caa573dd31d684cae90c180f0" dependencies = [ "either", "enum_kind", @@ -1466,9 +1473,9 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_base" -version = "0.108.5" +version = "0.108.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c83e51b6e1274835a90ed6fde32f0a651c07e1cd0af1615112daf040af949b9" +checksum = "72a6017cb4d0acba2c812fa0efef6eca3e5c78fd18eb5e559b143802b33c35f7" dependencies = [ "better_scoped_tls", "bitflags", @@ -1501,9 +1508,9 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_optimization" -version = "0.162.7" +version = "0.162.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "600f985266e07c417863fa143f60222fc9e334ee8df62bd263b905bbffd40bdb" +checksum = "5c744fcd5b28d3f00899e8b8bc2c00b131c49ed866e4f8753a693f3494e8082d" dependencies = [ "ahash", "dashmap", @@ -1526,9 +1533,9 @@ dependencies = [ [[package]] name = "swc_ecma_utils" -version = "0.102.3" +version = "0.102.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf1d7a5aa38ac829b53f62e36b56b79a048c269e850a3b557627c027bf3326dc" +checksum = "84f9c22fbb6d513d83fbb7b2c396bb71c53b25370cc1e11ea6a994d74b9186fa" dependencies = [ "indexmap", "num_cpus", @@ -1543,9 +1550,9 @@ dependencies = [ [[package]] name = "swc_ecma_visit" -version = "0.77.1" +version = "0.77.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f27eeaaddf87fed212a5ebbfecd4736d600e55c2bd1ac021f2274b12080eacd1" +checksum = "4891bc895524ce913b3eae7763201f39a621f4991c4d9868b9ea94875e84f149" dependencies = [ "num-bigint", "swc_atoms", @@ -1569,9 +1576,9 @@ dependencies = [ [[package]] name = "swc_error_reporters" -version = "0.12.1" +version = "0.12.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2123fd2c075bd9f6def83067e9a4c4bac9bdb5f064d94b50da6a9530594443b7" +checksum = "4fe0c4207f29551492d58a3de7dfde559651e2bcf83e7e8ebe1b1990aa851f7c" dependencies = [ "anyhow", "miette", @@ -1582,9 +1589,9 @@ dependencies = [ [[package]] name = "swc_fast_graph" -version = "0.16.1" +version = "0.16.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4cc77ca6811f36fddab8599ba25be82566537e420e183a211bbb9974b1f9fd0" +checksum = "9d0388c391aa752dc1b7c5b2c34b6167515370219e1d8c8cd74b3d0c204c81df" dependencies = [ "ahash", "indexmap", @@ -1594,9 +1601,9 @@ dependencies = [ [[package]] name = "swc_html" -version = "0.73.0" +version = "0.74.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43f32047aee7158c61e68bc5e548d04670ab3b30d191b362accca4d7fe9ac3ec" +checksum = "5721d31d66cc424fd1b3b65408b44a790ad7ea114cd90b20a19d00c849b49b26" dependencies = [ "swc_html_ast", "swc_html_codegen", @@ -1607,9 +1614,9 @@ dependencies = [ [[package]] name = "swc_html_ast" -version = "0.25.1" +version = "0.25.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e385c652af87670c5789d93cb1cdc6b16e7208f30eaa0136bcb187f83c7dd615" +checksum = "8f18b58568e8e4b3d346c50b255ed95b67c94360989ab7ddd49caa4ec043917c" dependencies = [ "is-macro", "serde", @@ -1620,9 +1627,9 @@ dependencies = [ [[package]] name = "swc_html_codegen" -version = "0.33.1" +version = "0.34.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "917df6cd80ec371d47614693e35b3f227d3b6eb1a1d4009fc85bcfa3f9580584" +checksum = "372e58e9009260d93fdd3a7f3b9c3115a944f37f77cdb9e4870a286868210cac" dependencies = [ "auto_impl", "bitflags", @@ -1649,9 +1656,9 @@ dependencies = [ [[package]] name = "swc_html_minifier" -version = "0.70.0" +version = "0.71.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b26be72f076e77087150868c96e8f453877091440f7301cc688948407027306" +checksum = "355861404bdb207249d4a9174f3c02289b0a8d3774e1a19e7383ef2077a7fe7a" dependencies = [ "once_cell", "serde", @@ -1678,9 +1685,9 @@ dependencies = [ [[package]] name = "swc_html_parser" -version = "0.30.1" +version = "0.31.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c5ffc6f7a0beef007618984b1edac2494a181f9b39a9235b5419d18bd81dbe2" +checksum = "7aec443a1f997da55f2badc4682deb14d5d723ad8ad517ee15251f4c5cc114c7" dependencies = [ "swc_atoms", "swc_common", @@ -1690,9 +1697,9 @@ dependencies = [ [[package]] name = "swc_html_utils" -version = "0.13.1" +version = "0.13.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa5f27998f0a460c339fe1f08bcb5f469f42f21bbc70e85a314125f9376fd180" +checksum = "b5bf4f48285dfb4689ab8e078b2d8eb7bdc917f547dd5239c53f795b52cf1ba8" dependencies = [ "once_cell", "serde", @@ -1702,9 +1709,9 @@ dependencies = [ [[package]] name = "swc_html_visit" -version = "0.25.1" +version = "0.25.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "628d5fb207d00a80a1c9c19585127de5e26f912cc8546b3395d6d9e8c4961fe4" +checksum = "90cff1af43c7a1d590e7942f02c2f758ed7f73ed741452d26a511d7baa2d0186" dependencies = [ "serde", "swc_atoms", @@ -1752,9 +1759,9 @@ dependencies = [ [[package]] name = "swc_timer" -version = "0.16.1" +version = "0.16.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "765212df8e0161a50d4771ac204637457e6326484e3fa0c15095cdd900df898e" +checksum = "b28eaac97cbb889b10179772171d6ef6893d0b6d4df94096a62f3b9df31c3735" dependencies = [ "tracing", ] @@ -1942,6 +1949,16 @@ dependencies = [ "tracing-log", ] +[[package]] +name = "triomphe" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1ee9bd9239c339d714d657fac840c6d2a4f9c45f4f9ec7b0975113458be78db" +dependencies = [ + "serde", + "stable_deref_trait", +] + [[package]] name = "typed-arena" version = "2.0.1" diff --git a/crates/css_node/Cargo.toml b/crates/css_node/Cargo.toml index 076e24f..73d702a 100644 --- a/crates/css_node/Cargo.toml +++ b/crates/css_node/Cargo.toml @@ -28,12 +28,12 @@ napi-derive = {version = "2", default-features = false, features = [ ]} serde = {version = "1", features = ["derive"]} serde_json = "1" -swc_common = { version = "0.28.1", features = ["sourcemap"] } -swc_css_ast = "0.112.0" -swc_css_codegen = "0.122.0" -swc_css_minifier = "0.87.0" -swc_css_parser = "0.121.0" -swc_error_reporters = "0.12.1" +swc_common = { version = "0.28.8", features = ["sourcemap"] } +swc_css_ast = "0.112.7" +swc_css_codegen = "0.122.7" +swc_css_minifier = "0.87.10" +swc_css_parser = "0.121.7" +swc_error_reporters = "0.12.8" swc_nodejs_common = "0.0.1" tracing = {version = "0.1.32", features = ["release_max_level_info"]} tracing-subscriber = {version = "0.3.9", features = ["env-filter"]} diff --git a/crates/html_node/Cargo.toml b/crates/html_node/Cargo.toml index d9865b5..5bba2bb 100644 --- a/crates/html_node/Cargo.toml +++ b/crates/html_node/Cargo.toml @@ -15,23 +15,23 @@ crate-type = ["cdylib"] [features] [build-dependencies] -napi-build = {version = "1"} +napi-build = { version = "1" } [dependencies] anyhow = "1" -napi = {version = "2", default-features = false, features = [ +napi = { version = "2", default-features = false, features = [ "napi3", "serde-json", -]} -napi-derive = {version = "2", default-features = false, features = [ +] } +napi-derive = { version = "2", default-features = false, features = [ "type-def", -]} -serde = {version = "1", features = ["derive"]} +] } +serde = { version = "1", features = ["derive"] } serde_json = "1" -swc_common = "0.28.1" -swc_error_reporters = "0.12.1" -swc_html = { version = "0.73.0", features = ["minifier"] } -swc_html_minifier = "0.70.0" +swc_common = "0.28.8" +swc_error_reporters = "0.12.8" +swc_html = { version = "0.74.7", features = ["minifier"] } +swc_html_minifier = "0.71.7" swc_nodejs_common = "0.0.1" -tracing = {version = "0.1.32", features = ["release_max_level_info"]} -tracing-subscriber = {version = "0.3.9", features = ["env-filter"]} +tracing = { version = "0.1.32", features = ["release_max_level_info"] } +tracing-subscriber = { version = "0.3.9", features = ["env-filter"] }