-
Notifications
You must be signed in to change notification settings - Fork 433
v2.0.0 Migration Guide
Here are the steps you need to perform to successfully migrate your v1.x.x widget to v2.0.0:
-
Update the dependency and make sure you are running Flutter v2.0+, Dart v2.12+
-
Parameters have moved around:
-
hint,initialTexthave moved toHtmlEditorOptions -
heightanddecorationhave moved toOtherOptions -
showBottomToolbarhas been removed -
options:has been renamed tohtmlEditorOptions: -
toolbarlist has moved toHtmlToolbarOptions->defaultToolbarButtons
-
-
All plugins except
SummernoteAtMentionhave been removed, all exceptAdditionalTextTagsandSummernoteEmojiare supported natively and enabled by default. UsedefaultToolbarButtonsto disablelistStyles,caseConverter,otherFile, ortextDirection. -
Toolbar constructors have been renamed:
-
Style->StyleButtons -
FontSetting->FontSettingButtons -
Font->FontButtons -
ColorBar->ColorButtons -
MiscFonthas been removed (the buttons are now underFontButtons) -
Paragraph->ParagraphButtons -
Insert->InsertButtons -
Misc->OtherButtons
-
-
Toolbar buttons are now disabled with
trueorfalse, like so:ParagraphButtons(lineHeight: false, caseConverter: false)- All buttons except one (
otherFile) are enabled by default, it is highly recommended to disable some in your implementation to avoid overwhelming users with options.
- All buttons except one (
-
If you use the plugin on Web, you should use the flag
--web-renderer=htmlfor the time being due to Flutter #54027
If you have any further questions, feel free to file an issue!