Skip to content

Commit

Permalink
[#69] Update readme for disableEditButton
Browse files Browse the repository at this point in the history
  • Loading branch information
maxfenton committed Nov 9, 2023
1 parent 605fb74 commit 2210074
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions docs/extras.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,15 @@ Regardless of logged-in state or permissions, the Craft Debug Bar will always be
## Front-end edit entry Links

When visiting an element URL on the front-end, an edit entry link to edit that element in the CP will be present in the lower left hand corner. This will always be present in the dev environment regardless of logged-in state or permissions.

In order to prevent these links from being cached by Blitz (or simply to remove it from any site), `^v5.0.4` adds a boolean `disableEditButton` option to the module config which prevents the `Edit Entry` links from being output. The default value is `false` but can be changed in a project’s `config/viget.php` to `true` or `!App::devMode()`:

```php
<?php

use craft\helpers\App;

return [
'disableEditButton' => !App::devMode(), // default is false
];
```

0 comments on commit 2210074

Please sign in to comment.