React-draft-wysiwyg: Paste without source styling

Created on 18 Dec 2017  路  7Comments  路  Source: jpuri/react-draft-wysiwyg

Hi,

Thanks for this great editor :)

When pasting from another editor, it keeps source's paragraph styling such as

<p style="text-align:left;"><span style="color: rgb(96,103,241);font-size: 27px;font-family: sofia-pro, sans-serif;">

Is there a way to disable this behaviour?

Thanks.

Most helpful comment

use the property stripPastedStyles
https://github.com/jpuri/react-draft-wysiwyg/issues/270
image

All 7 comments

Hi, if You use chrome you can just press right mouse button and "paste as plain text". This is a line below than the line "Paste"

Command+Shift+V for pasting can also be used for pasting without styles.

There is no option atm to otherwise disable this behavior.

use the property stripPastedStyles
https://github.com/jpuri/react-draft-wysiwyg/issues/270
image

Does the property stripPastedStyles work?
If it works then why this issue has not been closed?

@suryarsp just tried this in my own project and it does work (I'm using version 1.13.1, haven't tested any others)

@suryarsp me too, i just tried this and it does work!
current version 1.14.5

Was this page helpful?
0 / 5 - 0 ratings

Related issues

gyarasu picture gyarasu  路  4Comments

ananddodia picture ananddodia  路  4Comments

Huespal picture Huespal  路  3Comments

trongbang86 picture trongbang86  路  3Comments

dahudson88 picture dahudson88  路  3Comments