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

Upgrade babel to ^7.24 to remove dependency on core-js 2.6 #35

Closed
wants to merge 2 commits into from

Conversation

ampedweb
Copy link

@ampedweb ampedweb commented Jul 23, 2024

Tests seem to still pass after upgrading to a later version of Babel so hopefully this PR is OK?

The current core-js@2.6 package the babel packages rely on is deprecated, this removes the deprecated package and warnings related to it.

Happy to discuss though!

@zackad
Copy link
Owner

zackad commented Jul 23, 2024

running yarn install on my machine causing yarn.lock file to be updated.

diff --git a/yarn.lock b/yarn.lock
index 19bf3a8..fc364c6 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -40,7 +40,7 @@
   resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.24.8.tgz#58a4dbbcad7eb1d48930524a3fd93d93e9084c6f"
   integrity sha512-WzfbgXOkGzZiXXCqk43kKwZjzwx4oulxZi3nq2TYL9mOjQv6kYwul9mz6ID36njuL7Xkp6nJEfok848Zj10j/w==
 
-"@babel/template@^7.24":
+"@babel/template@^7.24.7":
   version "7.24.7"
   resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.24.7.tgz#02efcee317d0609d2c07117cb70ef8fb17ab7315"
   integrity sha512-jYqfPrU9JTF0PmPy1tLYHW4Mp4KlgxJD9l2nP9fD6yT/ICi554DmrWBAEYpIelzjHf1msDP3PxJIRt/nFNfBig==
@@ -49,7 +49,7 @@
     "@babel/parser" "^7.24.7"
     "@babel/types" "^7.24.7"
 
-"@babel/types@^7.24", "@babel/types@^7.24.7":
+"@babel/types@^7.24.7", "@babel/types@^7.24.9":
   version "7.24.9"
   resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.24.9.tgz#228ce953d7b0d16646e755acf204f4cf3d08cc73"
   integrity sha512-xm8XrMKz0IlUdocVbYJe0Z9xEgidU7msskG8BbhnTPK/HZ2z/7FP7ykqPgrUH+C+r414mNfNWam1f2vqOjqjYQ==

did you forget to commit the correct version of your lock file?

@ampedweb
Copy link
Author

@zackad Hmm this is strange. No it looks like I committed the correct one here. It was all part of the same commit as the updates. Could you try with yarn install --frozen-lockfile maybe?

@zackad
Copy link
Owner

zackad commented Jul 24, 2024

nope, it give me error.

yarn install v1.22.22
[1/5] Validating package.json...
[2/5] Resolving packages...
error Your lockfile needs to be updated, but yarn was run with `--frozen-lockfile`.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

seems like you have mismatch version between package.json and yarn.lock

diff --git a/package.json b/package.json
index 0ab3356..84d053d 100644
--- a/package.json
+++ b/package.json
@@ -19,8 +19,8 @@
         "test": "vitest --run"
     },
     "dependencies": {
-        "babel-template": "^6.26.0",
-        "babel-types": "^6.26.0",
+        "@babel/template": "^7.24.7",
+        "@babel/types": "^7.24.9",
         "he": "^1.2.0",
         "lodash": "^4.17.21",
         "prettier": "^3.0.0",,

maybe you could re-add @babel/template and @babel/types packages and commit the lockfile.

@ampedweb
Copy link
Author

@zackad There you go, see if that works! 👍

zackad added a commit that referenced this pull request Jul 24, 2024
Close #34
Merge #35

Following commits has been squashed before being merged:

ref: 8f18dcd
message: Upgrade babel to ^7.24 to remove dependency on core-js 2.6

ref: ac1b2f6
message: Recommit lockfile
@zackad
Copy link
Owner

zackad commented Jul 24, 2024

Merged via 79cf386

Thanks @ampedweb.

@zackad zackad closed this Jul 24, 2024
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.

2 participants