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

perf: add toJSON to performance class #37771

Closed
wants to merge 1 commit into from

Conversation

yashLadha
Copy link
Contributor

Added toJSON method to the InternalPerformance class as per the
convention followed in other performance classes and per the spec:
https://www.w3.org/TR/hr-time/#tojson-method

Fixes: #37623

@nodejs-github-bot nodejs-github-bot added needs-ci PRs that need a full CI run. perf_hooks Issues and PRs related to the implementation of the Performance Timing API. labels Mar 16, 2021
@jasnell
Copy link
Member

jasnell commented Mar 16, 2021

This should include a test

lib/perf_hooks.js Outdated Show resolved Hide resolved
@yashLadha
Copy link
Contributor Author

This should include a test

Yes will be adding it.

@yashLadha yashLadha force-pushed the add_to_json_performance branch 2 times, most recently from 551aa74 to 5647f64 Compare March 17, 2021 00:47
@yashLadha
Copy link
Contributor Author

Added test @jasnell

@yashLadha yashLadha force-pushed the add_to_json_performance branch 4 times, most recently from a439e79 to 93ca72e Compare March 17, 2021 01:49
lib/perf_hooks.js Outdated Show resolved Hide resolved
doc/api/perf_hooks.md Outdated Show resolved Hide resolved
@yashLadha yashLadha force-pushed the add_to_json_performance branch 2 times, most recently from 27a066c to 73e6da2 Compare March 23, 2021 06:33
lib/perf_hooks.js Outdated Show resolved Hide resolved
Added toJSON method to the InternalPerformance class as per the
convention followed in other performance classes and per the spec:
https://www.w3.org/TR/hr-time/#tojson-method

Fixes: nodejs#37623
@jasnell jasnell added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Apr 28, 2021
@nodejs-github-bot

This comment has been minimized.

@nodejs-github-bot

This comment has been minimized.

@nodejs-github-bot

This comment has been minimized.

@nodejs-github-bot
Copy link
Collaborator

@nodejs-github-bot
Copy link
Collaborator

nodejs-github-bot commented Apr 30, 2021

@jasnell
Copy link
Member

jasnell commented Apr 30, 2021

Landed in 93f0b4d

@jasnell jasnell closed this Apr 30, 2021
jasnell pushed a commit that referenced this pull request Apr 30, 2021
Added toJSON method to the InternalPerformance class as per the
convention followed in other performance classes and per the spec:
https://www.w3.org/TR/hr-time/#tojson-method

Fixes: #37623

PR-URL: #37771
Fixes: #37623
Reviewed-By: James M Snell <jasnell@gmail.com>
targos pushed a commit that referenced this pull request May 3, 2021
Added toJSON method to the InternalPerformance class as per the
convention followed in other performance classes and per the spec:
https://www.w3.org/TR/hr-time/#tojson-method

Fixes: #37623

PR-URL: #37771
Fixes: #37623
Reviewed-By: James M Snell <jasnell@gmail.com>
@targos targos mentioned this pull request May 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
author ready PRs that have at least one approval, no pending requests for changes, and a CI started. needs-ci PRs that need a full CI run. perf_hooks Issues and PRs related to the implementation of the Performance Timing API.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Performance should have a toJSON method
5 participants