How to implement html editor in product description


hi , everyone
i want to implement html editor in description of product description in reaction. like the one in this forum’s new topic description. any suggestions and ideas.


actually I am implementing trumbowyg html-editor in reaction. but when i edit description its not adding in description field and in schema


:roll_eyes: anyone, still has no idea


we don’t support HTML in product descriptions deliberately. This would impose security related issues that would need to be addressed carefully. For more details, please have a look into our FAQ’s, section “How to add HTML/markup to the product descriptions”:


But what if what I want just return line. Do some simple format for description. Or add a link into it.


I understand why you did that. But I really need some level customization for description. Or the presentation of the page is too simple. And we have relative strict access control over shop manager. So that I think it would be ok.

Just in case someone else feel interested. @amalan
Solution 1:
Solution 2:
imports/plugins/included/product-detail-simple/client/components/productField.js L140 ~

   if (this.props.element) {
      return React.createElement(this.props.element, {
        className: classNames,
        itemProp: this.props.itemProp,
        // children: renderHTML(`<div>${this.value ? this.value : ""}</div>`) Soloution 2
        dangerouslySetInnerHTML: {__html: this.value}

    return (
      <div className={classNames}>
        {/*{renderHTML(`<div>${this.value ? this.value : ""}</div>`)}*/} Solution 2
        <span dangerouslySetInnerHTML={{__html: this.value}} />