-
Notifications
You must be signed in to change notification settings - Fork 109
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
Improve Optimization Detective documentation #1782
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## trunk #1782 +/- ##
=======================================
Coverage 66.64% 66.64%
=======================================
Files 88 88
Lines 7015 7015
=======================================
Hits 4675 4675
Misses 2340 2340
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
… update/od-docs
The TODO here can be removed: performance/plugins/optimization-detective/storage/data.php Lines 57 to 68 in d94977f
This was solved with the implementation of ETag in #1722. |
… update/od-docs
… update/od-docs * 'trunk' of https://github.com/WordPress/performance: Bump yoast/phpunit-polyfills from 3.1.1 to 4.0.0 Bump phpstan/php-8-stubs from 0.4.9 to 0.4.10 Add ETag explainer to od_url_metric_freshness_ttl hook docs Fix format for multisite active plugins Include active plugins in URL Metric ETag data Add missing getters for OD_URL_Metric_Group_Collection props Increase default freshness TTL from 1 day to 1 week
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.
To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
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.
@westonruter Thanks, LGTM!
@@ -253,6 +253,77 @@ function od_optimize_template_output_buffer( string $buffer ): string { | |||
/** | |||
* Fires to register tag visitors before walking over the document to perform optimizations. | |||
* | |||
* Once a page has finished rendering and the output buffer is processed, the page contents are loaded into |
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.
Not opposed to this block for now, but this is so detailed I think it should rather be part of some docs/*.md
file. Maybe you can move (most of) it as part of #1857. This is probably relevant for one of the more detailed documentation articles to write, and we wouldn't want to have this much content duplicated between method docs and separate documentation.
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.
Yeah, as part of #1857 I'd love to have a process that would automatically extract the docs from phpdoc and dump it into the markdown files. That would ensure the documentation is as close to the code as possible (in PHP) while also being accessible for ease of reading (in Markdown).
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.
While a code reference like that would be helpful, I think large text chunks like this one here still fit better into a more detailed article, e.g. on how to write an Optimization Detective extension.
We'd probably want to avoid duplicating too much between those "manual" articles and automatically generated code reference as well.
This is a follow-up to #1763.
@access private
from interfaces which are intended to be exposed.@since
tags.See #1857 for follow-up tasks to further flesh out docs.