gpt4 book ai didi

mobile-website - 如何将 Amazon Kindle Web 浏览器置于文章模式

转载 作者:行者123 更新时间:2023-12-04 01:10:55 26 4
gpt4 key购买 nike

您如何通过 HTML 或 Javascript 将 Amazon Kindle 网络浏览器置于文章模式?

编者按:Kindle 3 浏览器不会自动检测某些页面为“文章”,并在尝试进入文章模式时给出错误消息。文章模式使用什么来确定要显示页面的哪个部分?

最佳答案

这与可读性有关系吗?
http://lifehacker.com/5163401/readability-bookmarklet-quick+formats-pages-for-smoother-text
实际JavaScript code for Readability ,这是基于启发式的:

// Study all the paragraphs and find the chunk that has the most <p>'s and keep it:


这似乎也与 Safari 5's Reader mode 有关.这是 required for Safari Reader :

This definitely needs more investigating, but so far, these appear to be the most important factors for Safari’s Reader functionality to kick in:

  • Use the right markup, i.e. make sure the most important content is wrapped inside a container element. Whether you use <article>, <div> or even <span> doesn’t seem to matter — as long as it’s not <p>.
  • The content needs to be long enough. Use enough words, use enough paragraphs, use enough punctuation. Every paragraph should have at least 100 characters.
  • Reader doesn’t work for local documents.

关于mobile-website - 如何将 Amazon Kindle Web 浏览器置于文章模式,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3588529/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com