lydiahallie
Repos
55
Followers
8697

A long list of (advanced) JavaScript questions, and their explanations :sparkles:

49959
6649

Repo related to the FrontendMasters course on JavaScript and React patterns

434
68

Events

Exclude Node 18 from engines

Created at 1 week ago

Bump versions

Created at 1 week ago

[next] Ensure test-next-local is run in CI (#7868)

  • Ensure test-next-local is run in CI

  • update turbo config

  • update timeout

  • update flakey test

[next] Allow edge api endpoints in Next.js (#7855)

Co-authored-by: JJ Kasper jj@jjsweb.site

[tests] Skip env vars for forks (#7873)

This fixes an issue when an external contributor submits a PR and the remote cache is not accessible

$ turbo run build
 ERROR No caches are enabled. You can try "turbo login", "turbo link", or ensuring you are not passing --remote-only to enable caching:  <nil>
• Packages in scope: @vercel/build-utils, @vercel/client, @vercel/frameworks, @vercel/go, @vercel/next, @vercel/node, @vercel/node-bridge, @vercel/python, @vercel/redwood, @vercel/remix, @vercel/routing-utils, @vercel/ruby, @vercel/static-build, @vercel/static-config, vercel

[tests] Conditionally set env vars (#7874)

This PR is a follow up to #7873 which didn't work as intended

[docs] Fix CONTRIBUTING.md grammar (#7575)

Fix: CONTRIBUTING.md grammar

Co-authored-by: Steven steven@ceriously.com

Publish Canary

  • vercel@24.2.5-canary.3
  • @vercel/next@2.8.67-canary.3

[tests] Fix tests with promises (#7880)

These tests are asynchronous and would sometimes fail if the second call started before the first call finished. This PR fixes the usage since the function returns a promise.

[tests] Add vc build integration test (#7876)

[cli] Add vc build integration test

Adds a vc build integration test to ensure the ncc'd CLI works as expected to supplement the unit tests from #7869.

Co-authored-by: Steven steven@ceriously.com

[node] Remove mkdirp-promise dependency (#7878)

There's no need to use this module since Node.js has recursive: true since Node v10.

Co-authored-by: Steven steven@ceriously.com

[build-utils][go][next][redwood][static-build] Fix path delimiter on windows (#7881)

This PR fixes an issue where the path delimiter was incorrect for windows and caused yarn (and other global CLIs) to no longer be found.

https://github.com/vercel/vercel/runs/6602572000?check_suite_focus=true#step:13:1357

[tests] Bump turbo to 1.2.14 (#7887)

This should fix the caching problem

https://github.com/vercel/turborepo/releases/tag/v1.2.14

[examples] Update SvelteKit example with latest boilerplate (#7892)

Replaces https://github.com/vercel/vercel/pull/7674 with the latest SvelteKit boilerplate.

Publish Stable

  • @vercel/build-utils@3.1.1
  • vercel@24.2.5
  • @vercel/client@11.0.4
  • @vercel/frameworks@1.0.0
  • @vercel/go@1.4.4
  • @vercel/next@2.9.0
  • @vercel/node@1.15.4
  • @vercel/python@2.3.4
  • @vercel/redwood@0.8.4
  • @vercel/remix@0.0.2
  • @vercel/ruby@1.3.7
  • @vercel/static-build@0.26.0

[tests] Update domain tests from .org to .com (#7896)

Use a regex matcher and change the .org to .com

[cli] update update-notifier to fix notification of non-latest (#7897)

Looks like this is a bug in update-notifier, but they smoothed it over with a change that was deployed in 5.0.0. We’re currently on 4.1.0.

This can cause an update notification for a PREVIOUS version, like so:

$  vc --version
> UPDATE AVAILABLE Run `npm i -g vercel@latest` to install Vercel CLI 24.2.5-canary.3
> Changelog: https://github.com/vercel/vercel/releases/tag/vercel@24.2.5-canary.3
Vercel CLI 24.2.5
24.2.5

While we're here, also sets the updatecheckinterval to 1 week.


Previous PR: https://github.com/vercel/vercel/pull/4896

Revert "[next] Allow edge api endpoints in Next.js" (#7898)

Reverts vercel/vercel#7855

We can re-land after we ensure the cases we have found failing are resolved.

[static-config] Support extracting export const config from swc's AST (#7791)

This PR adds support for extracting config from swc's AST. static-config supports parsing from the source program but in some cases we already have parsed an AST to do other static code analysis.

Related Issues

None

📋 Checklist

Tests

  • [x] The code changed/added as part of this PR has been covered with tests
  • [x] All tests pass locally with yarn test-unit

Code Review

  • [ ] This PR has a concise title and thorough description useful to a reviewer
  • [ ] Issue from task tracker has a link to this PR

[tests] Fix turbo cache invalidation for GH Actions RUNNER_OS (#7899)

This PR fixes an issue where turbo was caching the result regardless of OS by adding the env var RUNNER_OS to the cache key.

https://docs.github.com/en/actions/learn-github-actions/environment-variables#detecting-the-operating-system

Publish Canary

  • vercel@24.2.6-canary.0
  • @vercel/next@2.9.1-canary.0
  • @vercel/static-config@1.0.2-canary.0

[build-utils] Fix warning for package.json engines (#7900)

This PR updates the way we handle warning for engines.node in package.json.

  • should not warn when the engines version satisfies the project settings (previously it was an exact match)
  • should warn when engines version is exact instead of range since it cannot be satisfied exactly
  • should warn when engines version is greater than since it might introduce breaking changes for a future node.js version
Created at 1 week ago

Add support for nested page-data requests and update status code

Minify GraphQL Engine

Add conditionals to routes/func generation

Rm log

Created at 1 week ago

Exclude lib files from API routes

Created at 1 week ago

Fix API routes and remove 500 HTML from functions

Created at 1 week ago

[node] Add WebAssembly importing support for the @vercel/node builder (#8204)

  • [node] Add WebAssembly importing support for the @vercel/node builder

  • add comment about the original source

  • trim down values to only what is required for esbuild wrapping logic

  • Revert "trim down values to only what is required for esbuild wrapping logic"

This reverts commit c04dacad99f25156938dccdf2f29aac6e8282564.

Co-authored-by: Sean Massa EndangeredMassa@gmail.com

Publish Stable

  • @vercel/build-utils@5.0.5
  • vercel@27.3.0
  • @vercel/client@12.1.4
  • @vercel/go@2.0.9
  • @vercel/hydrogen@0.0.6
  • @vercel/next@3.1.9
  • @vercel/node@2.5.0
  • @vercel/python@3.1.1
  • @vercel/redwood@1.0.10
  • @vercel/remix@1.0.11
  • @vercel/ruby@1.3.17
  • @vercel/static-build@1.0.10

[tests] Speed up vc tarball (#8261)

This updates the API that generates tarballs so that it doesn't need to generate tarballs for every Serverless Function and instead generates it one time. This cuts the time in half.

[node] trim down values to only what is required for esbuild wrapping logic (#8260)

The edge runtime context we were providing was necessary to have ncc-bundled code run, but after switching to esbuild, we didn't update this list.

This PR trims the values down to only what's necessary for esbuild-bundled code to run. It also adds comments about why these values are necessary.

[tests] Update tests to run with vercel cli tarball (#8257)

This PR update the tests suite to wait for Vercel CLI tarball and then use that tarball to run E2E tests.

This is valuable because it will package all the packages in this monorepo to make the tests follow more closely what will happen in production once merged.

Since the current "Find Changes" step takes about 2 minutes, we run that first (it happens concurrently with the tarball preparation). Then once we complete "Find Changes" we wait for the tarball but it will likely be ready by that point since it also takes about 2 minutes. After both of those steps, the E2E tests continue as usual but with the VERCEL_CLI_VERSION set to the tarball.

  • Related to #7967
  • Closes #8245
  • Closes #8227

[node] Remove .toString() in nft readFile() hook (#8263)

The nft readFile() hook accepts Buffer type so there's no reason to .toString() here.

[cli] Add 'alias' command to help screen and alphabetize commands (#8256)

The alias command has been added to the vercel --help screen.

Related Issues

https://linear.app/vercel/issue/VCCLI-221/alias-command-missing-on-vc-h-help-screen

📋 Checklist

Tests

  • [x] The code changed/added as part of this PR has been covered with tests
  • [x] All tests pass locally with yarn test-unit

Code Review

  • [ ] This PR has a concise title and thorough description useful to a reviewer
  • [ ] Issue from task tracker has a link to this PR

[node] Consider "browser" and "module" fields in package.json when tracing Edge Functions (#8262)

For Edge Functions, we are now considering the "browser" and "module" fields of packages to find the proper entrypoint. This PR updates @vercel/node to consider those same fields when using the node-file-trace tracing, so that the proper files get included in the output Edge Function.

[tests] Remove turbo's dependsOn to speed up tests (#8264)

Since CI is already setup to run Build and then Test, we don't need to add it as an explicit turbo dependency so this PR removes dependsOn: ['build'] from each test task.

In fact, the test-unit step doesn't need build in most cases now that jest is configured to run the TS sources directly.

This PR will also improve the time it takes to run the "Find Changes" job since it can ask jest for relevant files that changed without waiting for a build. This drops the time down from 2 minutes to 8 seconds.

Publish Stable

  • @vercel/build-utils@5.0.6
  • vercel@27.3.1
  • @vercel/client@12.1.5
  • @vercel/fs-detectors@2.0.2
  • @vercel/go@2.0.10
  • @vercel/hydrogen@0.0.7
  • @vercel/next@3.1.10
  • @vercel/node@2.5.1
  • @vercel/python@3.1.2
  • @vercel/redwood@1.0.11
  • @vercel/remix@1.0.12
  • @vercel/ruby@1.3.18
  • @vercel/static-build@1.0.11

[cli] Fix vc build with legacy @now/static (#8273)

There was a special case for @vercel/static but vc build was missing a special case for the legacy @now/static, which should work the same way.

[tests] Run dev e2e against same cli version (#8274)

The dev integration tests compare vc dev with a real deployment to make sure the results are the same. This PR ensures the deployment uses the same version of Vercel CLI as the local vc dev instance.

Co-authored-by: Sean Massa EndangeredMassa@gmail.com

[all] Revert ncc back to 0.24.0 (#8276)

Publish Stable

  • @vercel/build-utils@5.0.7
  • vercel@27.3.2
  • @vercel/client@12.1.6
  • @vercel/go@2.0.11
  • @vercel/hydrogen@0.0.8
  • @vercel/next@3.1.11
  • @vercel/node@2.5.2
  • @vercel/python@3.1.3
  • @vercel/redwood@1.0.12
  • @vercel/remix@1.0.13
  • @vercel/ruby@1.3.19
  • @vercel/static-build@1.0.12

[cli] Fix env delta message (#8271)

Co-authored-by: Sean Massa EndangeredMassa@gmail.com Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>

Publish Stable

  • vercel@27.3.3

update edge-runtime to allow instanceof to work with primitives (#8242)

  • update edge-runtime to allow instanceof to work with primitives

  • finishin upgrading edge-runtime

  • update to latest

  • fix merge

  • remove dev only from test

[fs-detectors] Exclude the middleware builder if it's a Next.js app (#8239)

[examples] Update Docusaurus 2 template for stable (#8286)

[go] remove meta.isDev references and restore partial tests (#8287)

Remove meta.isDev checks inside the build function because it's never set there. Instead, startDevServer would be used.

Also restored the Go tests in a partial form. Will fix the Go builder issues and make sure those features are tested completely in follow-up PRs.

Created at 2 months ago

Add test for default starter demo

Created at 2 months ago

Fix pages retrieval and update _page-data handler

Created at 2 months ago

Add test with default starter demo

Created at 2 months ago

Update CSS and og image

Merge branch 'main' of https://github.com/lydiahallie/javascript-react-patterns

Created at 2 months ago