Skip to content

downgrade js function vitest dependency to support node 21#245

Merged
lopert merged 1 commit intomainfrom
lopert.downgrade-vitest-for-function-templates
May 16, 2025
Merged

downgrade js function vitest dependency to support node 21#245
lopert merged 1 commit intomainfrom
lopert.downgrade-vitest-for-function-templates

Conversation

@lopert
Copy link
Contributor

@lopert lopert commented May 16, 2025

Background

Vitest 3.1.3 uses Vite 6+, which in turn does not support node 21.

The CLI currently supports node 21, so our templates need to work on that version.

Solution

Downgrades vitest dep in our function js templates to v2.
Did a find and replace of "vitest": "^3.1.3" -> "vitest": "2.1.9" in all package.json.liquid files.

Tophat

Ran npm install within my function directory with various versions of node and the vitest dep.

Checklist

  • I have 🎩'd these changes
  • I have squashed my commits into chunks of work with meaningful commit messages

@lopert lopert requested review from andrewhassan and otheriault May 16, 2025 14:15
@lopert lopert merged commit 665c6e8 into main May 16, 2025
3 checks passed
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