Skip to content

v0.52.0

@michaelfaith michaelfaith tagged this 10 Nov 18:39
<!-- 👋 Hi, thanks for sending a PR to package-json-validator! 💖
Please fill out all fields below and make sure each item is true and [x]
checked.
Otherwise we may not be able to review your PR. -->

## PR Checklist

- [x] Addresses an existing open issue: fixes #535
- [x] That issue was marked as [`status: accepting
prs`](https://github.com/JoshuaKGoldberg/package-json-validator/issues?q=is%3Aopen+is%3Aissue+label%3A%22status%3A+accepting+prs%22)
- [x] Steps in
[CONTRIBUTING.md](https://github.com/JoshuaKGoldberg/package-json-validator/blob/main/.github/CONTRIBUTING.md)
were taken

## Overview

This change adds a new `validateEngines` function that validates the
value of the "engines" field of a package.json. It returns a Result
object with any issues detected.

The new function is a bit stricter than what the monolith `validate`
function was checking. It was only checking if the value was an object.
Now we're doing that, but also checking that the values and keys are all
non-empty strings.
Assets 2
Loading