-
Notifications
You must be signed in to change notification settings - Fork 14.4k
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
chore(number-formatter): upgrade pretty-ms to 9.1.0 #30599
Conversation
}); | ||
test('format milliseconds in human readable format with default options', () => { | ||
const formatter = createDurationFormatter(); | ||
expect(formatter(-1000)).toBe('-1s'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note the added negative duration tests that previously weren't supported.
@@ -17,7 +17,7 @@ | |||
* under the License. | |||
*/ | |||
|
|||
import prettyMsFormatter from 'pretty-ms'; | |||
import prettyMilliseconds, { Options } from 'pretty-ms'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Renaming the default export to prettyMilliseconds
, as that's what it's called in the source, and pull in Options
via the newly exposed named export.
SUMMARY
Bump
pretty-ms
from 7.0.0 to 9.1.0, as this package hasn't been bumped in a long time. Notable changes:colonNotation
for sub-second durations (the lock file was actually already pointing to 7.0.1)Other changes:
describe
+it
totest
.jest
working with the new version, aspretty-ms
andparse-ms
are now fully ESM.BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
TESTING INSTRUCTIONS
ADDITIONAL INFORMATION