DOC-3388: Add getContent and setContent examples to save-content partial#4052
Merged
kemister85 merged 1 commit intofeature/8/DOC-3387from Apr 13, 2026
Merged
Conversation
Add programmatic get/set content section with runnable examples
using editor.getContent(), getContent({ format: 'text' }), and
editor.setContent() to address Context7 benchmark Q3 (12/100).
metricjs
approved these changes
Apr 13, 2026
ShiridiGandham
approved these changes
Apr 13, 2026
kemister85
added a commit
that referenced
this pull request
Apr 13, 2026
* DOC-3388: Add getContent and setContent examples to save-content partial (#4052) Add programmatic get/set content section with runnable examples using editor.getContent(), getContent({ format: 'text' }), and editor.setContent() to address Context7 benchmark Q3 (12/100). * DOC-3389: Strengthen add-css-options page for custom content CSS (#4053) Update description and add keywords for content_css and content_style. Add intro paragraph explaining the two options to address Context7 benchmark Q8 (0/100). * DOC-3390: Add editor.on('change') example to events page (#4054) Add content change callback example using setup option and editor.on('change') to address Context7 benchmark Q4 (30/100). * DOC-3391: Add addButton and addCommand example to creating-a-plugin (#4055) * DOC-3391: Add addButton and addCommand example to creating-a-plugin Add toolbar button section showing PluginManager.add with editor.ui.registry.addButton and editor.addCommand to address Context7 benchmark Q9 (15/100). * Update modules/ROOT/pages/creating-a-plugin.adoc Co-authored-by: Millie <millie.macdonald@tiny.cloud> --------- Co-authored-by: Millie <millie.macdonald@tiny.cloud> * DOC-3392: Add programmatic mode.set example to readonly docs (#4056) Add example showing editor.mode.set('readonly') and editor.mode.set('design') for runtime mode switching to address Context7 benchmark Q7 (25/100). * DOC-3393: Add plugins and toolbar multi-plugin example to quickstart (#4057) Add "Configure plugins and toolbar" section with plugins: 'image code' and toolbar example to the quickstart partial to address Context7 benchmark Q2 (56/100). * DOC-3394: Add content filtering intro to content-filtering page (#4058) Update description and keywords to mention valid_elements, invalid_elements, extended_valid_elements. Add intro paragraph summarizing key filtering options to address Context7 benchmark Q10 (22/100). * DOC-3395: Improve quickstart keywords for selector/ID discoverability (#4059) Add selector, textarea, id, tinymce.init keywords to all quickstart pages (cloud, npm, php, .net, zip) to address Context7 benchmark Q1 (62/100). * DOC-3396: Improve custom-toolbarbuttons and file-image-upload metadata (#4060) Update description and keywords for custom-toolbarbuttons (addButton, custom button), file-image-upload (images_upload_handler), and upload-images pages to address Context7 benchmark Q5/Q6 (25/100 each). --------- Co-authored-by: Millie <millie.macdonald@tiny.cloud>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
save-content.adocwith runnableeditor.getContent()andeditor.setContent()examplesSource validation
editor.getContent(args?)confirmed atEditor.ts:880-883editor.setContent(content, args?)confirmed atEditor.ts:858-860getContent({ format: 'text' })option confirmed in source JSDocTest plan
Editor.ts)tinymce.activeEditorconsistent with source JSDoc