Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,5 +43,9 @@
"globals": "^15.14.0",
"jest": "^29.7.0",
"prettier": "3.5.0"
},
"engineStrict": false,
"engines": {
"node": ">=20.0.0"
}
}
1 change: 1 addition & 0 deletions tools/.tool-versions
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
golang 1.23.0
nodejs 20.9.0
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looked at the package json reference, we can specify there if we want: https://docs.npmjs.com/cli/v11/configuring-npm/package-json#engines

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. That is very common practice. Adding it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

adding it to the package.json just produces warnings

2 changes: 1 addition & 1 deletion tools/postman/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ transform_collection:

.PHONY: transform_collection_js
transform_collection_js:
node ./scripts/transform-postman.cjs
node ./scripts/transform-postman.js

.PHONY: transform_collection_test
transform_collection_test:
Expand Down
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

node uses commonjs by default should this be .mjs

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I understand it esm is the standard nowadays

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have all files as js (which should be fine) using (mjs) import format.
This PR makes single change to align to that format.

If we want to change extension or import format let me know. Can do it across repo comprehensively.

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const fs = require('fs');
const path = require('path');
const _ = require('lodash');
import fs from 'fs';
import path from 'path';
import _ from 'lodash';

/**
# Prepare collection for Postman API
Expand Down
Loading