How to add WYSIWYG Editor in Magento 2 System Configuration

How to add WYSIWYG Editor in Magento 2 System Configuration

WYSIWYG is an HTML editor for easy content editing. WYSIWYG enables adding and formatting the content providing “What You See Is What You Get ” view. Preview the end result in the editing phase itself and thus avoid handling HTML tags! Interesting, isn’t it? 😄

However, the default Magento 2 does not offer WYSIWYG editor in the system configuration. Admin may want to display messages in a certain manner in frontend. The WYSIWYG editor makes the task simpler.

To overcome the default Magento 2 limitation, implement the below method to add WYSIWYG editor in Magento 2 system configuration.

Method to Add WYSIWYG Editor in Magento 2 System Configuration:

  1. Add below code in the system.xml file
  2. Create new file Editor.php at Vendor\Extension\Block\Adminhtml folder

That’s all about WYSIWYG editor in system configuration for Magento 2!

Once you implement this solution, please refer here

I’d like to hear the readers’ opinions or solve their doubts mentioned in the Comments section below 🙂

Thank you.

5
(based on 8 Reviews)

Sanjay is a co-founder at Meetanshi. He is a Certified Magento Developer who loves creating Magento E-commerce solutions. When he is not engrossed with anything related to Magento, he loves to play cricket.

Leave a Reply