Issue #3173πŸ’¬ AnsweredOpened Dec 8, 2020by niveth092 reactions

How to remove the eye-slash button in preview mode?

Quick answerby robsonsobral❀ 1

> I'd suggest extending the original Preview commandThank you for reply @artf . Is there any documentation or sample code about extending an existing command? https://grapesjs.com/docs/modules/Commands.html#extending

Read full answer below ↓

Question

Hi @artf ! I have created a web builder using GrapesJS. I want to remove the eye-slash button in preview mode and replace it with the back button. How to do it? Kindly please help me.

Answers (4)

robsonsobralβ€’ Dec 17, 2020

> I'd suggest extending the original Preview commandThank you for reply @artf . Is there any documentation or sample code about extending an existing command? https://grapesjs.com/docs/modules/Commands.html#extending

collindutterβ€’ Jan 19, 2021

@niveth09 here is the code for extending the preview command without the eye button:

artfβ€’ Dec 16, 2020

I'd suggest extending the original Preview command

GJSBlockβ€’ May 17, 2026

Thanks for reporting this, @niveth09. Great question about How to remove the eye-slash button in preview mode?. The recommended approach with GrapesJS is to use the event-driven API. Start here: Check the GrapesJS documentation for your specific module Look for the on() event listener method Most o...

Related Questions and Answers

Continue research with similar issue discussions.

Paid Plugins That Match This Issue

Curated by issue keywords and label relevance to help you ship faster.

View all plugins

Loading paid plugin recommendations...

Free option

Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.

Browse free plugins β†’
Premium option

Premium plugins ship with support, regular updates, and production-ready features β€” save days of integration work.

Browse premium plugins β†’

Related tutorials

In-depth guides on the same topic.

All tutorials β†’

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.