Regarding Gutenberg and blocks
-
This is regarding recent topics about Gutenberg and blocks.
From @tidus457 @userphpgerm1 @nahuaiA few facts :
– The DeepL translation API (used by this plugin) handles complex HTML content pretty well and returns proper WP blocks. This is good news.
– The Gutenberg Javascript API (also used by this plugin to get and update strings) is a mess. I wish it wasn’t.I’ve asked before ( https://ww.wp.xz.cn/support/topic/getting-and-modifying-gutenberg-post-content-with-javascript/ ) and more recently ( https://github.com/WordPress/gutenberg/issues/28488 ) for a simple way to update post_content within Gutenberg editor with no answer.
Right now, I’m getting the translated post content from the API, splitting it in JS into more-or-less paragraphs and inserting paragraphs. That’s why you get a paragraph tags soup.
Current solution : disable Gutenberg. Even the code editor view has no clear method to update post_content.
Precision : the (paid) batch translation extension of this plugin works well, by fetching and updating the content directly from and into the database. It sends raw content to DeepL and get properly translated content and update the database.
However, I’m not happy with this situation and do NOT want to push a paid extension to have this plugin working with Gutenberg.
So my goal is to get this plugin able to work within Gutenberg without the need to purchase anything (which is not free for other reasons, eg the ability to translate multiple posts in batches)I’m actively working on this problem.
The topic ‘Regarding Gutenberg and blocks’ is closed to new replies.