tome export

This commit is contained in:
Oliver Davies 2025-05-30 02:14:32 +01:00
parent 52278c3a53
commit 7a52afab5f
960 changed files with 3670 additions and 2229 deletions

View file

@ -82,15 +82,15 @@
],
"body": [
{
"value": "\n <p>When most people think of \"Don't repeat yourself\" or DRY, they probably think about not duplicating logic in code.<\/p>\n\n<p>If you've written some functionality once, you should avoid writing it again.<\/p>\n\n<p>I was recently browsing the code for an open source package and saw this:<\/p>\n\n<pre><code class=\"php\">\/**\n * Flush everything.\n *\/\npublic function flush(): void;\n\n\/**\n * Sets the formatter.\n *\/\npublic function setFormatter(FormatterInterface $formatter): void;\n\n\/**\n * Gets the formatter.\n *\/\npublic function getFormatter(): FormatterInterface;\n<\/code><\/pre>\n\n<p>This is another instance of repetition.<\/p>\n\n<p>The docblocks are just repeating what the code already tells me.<\/p>\n\n<p>I can understand from the method names what each function does, and I can see what parameters they have and their types.<\/p>\n\n<p>I can see if each method returns anything and, if so, what type it returns - e.g. <code>getFormatter<\/code> returns a <code>FormatterInterface<\/code>.<\/p>\n\n<p>I think these docblocks aren't needed and in my projects, would suggest they be removed.<\/p>\n\n<p>Unless they're adding more information, such as <a href=\"/daily\/2025\/03\/21\/phpdoc\">PHPStan PHPDoc types<\/a>, there's no need to repeat what the code already says.<\/p>\n\n ",
"value": "\n <p>When most people think of \"Don't repeat yourself\" or DRY, they probably think about not duplicating logic in code.<\/p>\n\n<p>If you've written some functionality once, you should avoid writing it again.<\/p>\n\n<p>I was recently browsing the code for an open source package and saw this:<\/p>\n\n<pre><code class=\"php\">\/**\n * Flush everything.\n *\/\npublic function flush(): void;\n\n\/**\n * Sets the formatter.\n *\/\npublic function setFormatter(FormatterInterface $formatter): void;\n\n\/**\n * Gets the formatter.\n *\/\npublic function getFormatter(): FormatterInterface;\n<\/code><\/pre>\n\n<p>This is another instance of repetition.<\/p>\n\n<p>The docblocks are just repeating what the code already tells me.<\/p>\n\n<p>I can understand from the method names what each function does, and I can see what parameters they have and their types.<\/p>\n\n<p>I can see if each method returns anything and, if so, what type it returns - e.g. <code>getFormatter<\/code> returns a <code>FormatterInterface<\/code>.<\/p>\n\n<p>I think these docblocks aren't needed and in my projects, would suggest they be removed.<\/p>\n\n<p>Unless they're adding more information, such as <a href=\"\/daily\/2025\/03\/21\/phpdoc\">PHPStan PHPDoc types<\/a>, there's no need to repeat what the code already says.<\/p>\n\n ",
"format": "full_html",
"processed": "\n <p>When most people think of \"Don't repeat yourself\" or DRY, they probably think about not duplicating logic in code.<\/p>\n\n<p>If you've written some functionality once, you should avoid writing it again.<\/p>\n\n<p>I was recently browsing the code for an open source package and saw this:<\/p>\n\n<pre><code class=\"php\">\/**\n * Flush everything.\n *\/\npublic function flush(): void;\n\n\/**\n * Sets the formatter.\n *\/\npublic function setFormatter(FormatterInterface $formatter): void;\n\n\/**\n * Gets the formatter.\n *\/\npublic function getFormatter(): FormatterInterface;\n<\/code><\/pre>\n\n<p>This is another instance of repetition.<\/p>\n\n<p>The docblocks are just repeating what the code already tells me.<\/p>\n\n<p>I can understand from the method names what each function does, and I can see what parameters they have and their types.<\/p>\n\n<p>I can see if each method returns anything and, if so, what type it returns - e.g. <code>getFormatter<\/code> returns a <code>FormatterInterface<\/code>.<\/p>\n\n<p>I think these docblocks aren't needed and in my projects, would suggest they be removed.<\/p>\n\n<p>Unless they're adding more information, such as <a href=\"/daily\/2025\/03\/21\/phpdoc\">PHPStan PHPDoc types<\/a>, there's no need to repeat what the code already says.<\/p>\n\n ",
"processed": "\n <p>When most people think of \"Don't repeat yourself\" or DRY, they probably think about not duplicating logic in code.<\/p>\n\n<p>If you've written some functionality once, you should avoid writing it again.<\/p>\n\n<p>I was recently browsing the code for an open source package and saw this:<\/p>\n\n<pre><code class=\"php\">\/**\n * Flush everything.\n *\/\npublic function flush(): void;\n\n\/**\n * Sets the formatter.\n *\/\npublic function setFormatter(FormatterInterface $formatter): void;\n\n\/**\n * Gets the formatter.\n *\/\npublic function getFormatter(): FormatterInterface;\n<\/code><\/pre>\n\n<p>This is another instance of repetition.<\/p>\n\n<p>The docblocks are just repeating what the code already tells me.<\/p>\n\n<p>I can understand from the method names what each function does, and I can see what parameters they have and their types.<\/p>\n\n<p>I can see if each method returns anything and, if so, what type it returns - e.g. <code>getFormatter<\/code> returns a <code>FormatterInterface<\/code>.<\/p>\n\n<p>I think these docblocks aren't needed and in my projects, would suggest they be removed.<\/p>\n\n<p>Unless they're adding more information, such as <a href=\"http:\/\/default\/daily\/2025\/03\/21\/phpdoc\">PHPStan PHPDoc types<\/a>, there's no need to repeat what the code already says.<\/p>\n\n ",
"summary": null
}
],
"feeds_item": [
{
"imported": "1970-01-01T00:33:45+00:00",
"imported": "1970-01-01T00:32:50+00:00",
"guid": null,
"hash": "0dcfb92613016648b8799e1ee65ada87",
"target_type": "feeds_feed",