Issue with Additional JavaScript from "划词翻译" and "沉浸式翻译" Extensions in Saved HTML Files #1521
-
I've been using the SingleFile extension to save web pages, and I noticed that the saved HTML files have some unusual characters at the end. After some troubleshooting, I found that this issue is caused by the "划词翻译" and "沉浸式翻译" extensions. These extensions add some JavaScript scripts to the end of the HTML files, which increases the file size by approximately 400KB-800KB. Could you please look into this issue? It would be great if SingleFile could handle these extensions' scripts more effectively or provide an option to exclude them. Thank you for your help! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
Through Chrome's DevTools, I can see these two extra divs. Is there any way to exclude them? |
Beta Was this translation helpful? Give feedback.
-
Referring to the example in this document step 5, I wrote this script and it seems worked. https://greasyfork.org/zh-CN/scripts/502328-remove-temporary-elements-for-singlefile/code Is there anything that can be improved? |
Beta Was this translation helpful? Give feedback.
From a technical point of view, the implementation seems perfect :)