How can I convert string to HTML encoded string in Flutter.
This is an example string
This is the sample text & special character
also new line
I want to convert like this
This is the sample text & special character <br> also new line
Not only &
I want all of the HTML entities available.
I found HTML to string everywhere But not String to HTML anywhere! I want reversed/opposite feature what html_unescape:
provide!
CodePudding user response:
I think this is what you're looking for:
https://api.flutter.dev/flutter/dart-convert/HtmlEscape-class.html