craftcms / docs

Documentation for Craft CMS, Craft Commerce, and other official products.
https://craftcms.com/docs
38 stars 144 forks source link

[Content]: `autosaveDrafts` 4.x docs warning is incorrect #534

Closed rmales closed 7 months ago

rmales commented 10 months ago

Product

Craft CMS

Description

In the 4.x docs the warning about disabling the autosaveDrafts settings says doing so will also disable live preview, which doesn't seem to be the case. The 3.x documentation warning seems to be accurate when it says live preview will save drafts even if the setting is disabled. 4.x https://craftcms.com/docs/4.x/config/general.html#autosavedrafts 3.x https://craftcms.com/docs/3.x/config/config-settings.html#autosavedrafts

Also noted here https://github.com/craftcms/docs/commit/7d64fcc3d50abcf5c93fe1328519fb52be0815e0#commitcomment-87336001

AugustMiller commented 10 months ago

Ah, this is a bit of a mystery… in addition to it being deprecated in 4.0.0, no equivalent “fluent” method was added in 4.2.0, so the example/syntax is actually invalid. 😬

I will submit a PR for this upstream in craftcms/cms, which is how we generate the configuration docs!

AugustMiller commented 7 months ago

We ended up discovering a bug with Live Preview that may have influenced this comment, originally; @i-just submitted a patch for it, this morning!

That PR also updates the relevant docblock, which will propagate back to the auto-generated config reference after the next release.

Thanks for the report! 💞