vigetlabs / craft-viget-base

http://code.viget.com/craft-viget-base/
7 stars 3 forks source link

[#69] Add `disableEditButton` option to module config #70

Closed maxfenton closed 10 months ago

maxfenton commented 10 months ago

Add a disableEditButton configuration option and check that when deciding whether or not to output an Edit Entry button on the front-end.

This allows us to set a value in config/viget.php to bypass the built-in logic.

maxfenton commented 10 months ago

This is working as expected on https://staging.loveyourmindtoday.org/life-challenges/workplace-issues-unemployment — when I change the .env to set DEV_MODE to false, the red button disappears.

(And setting DEV_MODE to true prevents Blitz caching so flipping that back and forth does not cause stuck caches with the button)

ten1seven commented 10 months ago

@maxfenton can you please add info about this to the docs?