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

Specify Node Engine Constraint in package.json #2096

Open
han3zeng opened this issue Jan 31, 2024 · 0 comments
Open

Specify Node Engine Constraint in package.json #2096

han3zeng opened this issue Jan 31, 2024 · 0 comments
Labels
type:feature A feature request

Comments

@han3zeng
Copy link

han3zeng commented Jan 31, 2024

Description

I think it would be better to specify "engines": { "node": "18 || 20" } in package.json for the following packages:
@marko
@marko/compiler
@marko/babel-utils
@marko/translator-default

Why

The four packages all depend on @luxass/strip-json-comments@^1.1.1 either directly or indirectly. The package defines "engines": { "node": ">=18" } in package.json. Including node engine constraint in package.json of marko-packages, it could benefit all users in two ways.

Firstly, if users update multiple packages at once and encounter an Unsupported Engine error, they could easily identify the direct dependencies that caused the issue. Secondly, in my case, I rely on Renovate for automated dependency updates. The platform has a setting call constraintsFiltering which allows developers to filter out all Unsupported Engine packages during updates. The feature only works on direct dependencies, so if we specify the engine constraint, developers using the platform can have a smoother automation process.

Possible Implementation & Open Questions

#2097

Is this something you're interested in working on?

Yes

@han3zeng han3zeng added the type:feature A feature request label Jan 31, 2024
@han3zeng han3zeng changed the title Specify "engines": { "node": "18 || 20" }` in package.json Specify "engines": { "node": "18 || 20" } in package.json Jan 31, 2024
@han3zeng han3zeng changed the title Specify "engines": { "node": "18 || 20" } in package.json Specify "engines": { "node": "18 || 20" } in package.json Jan 31, 2024
@han3zeng han3zeng changed the title Specify "engines": { "node": "18 || 20" } in package.json Specify Node Engine Constraint in package.json Jan 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:feature A feature request
Projects
None yet
Development

No branches or pull requests

1 participant