tea3 / hexo-generator-amp

AMP ⚡ HTML (Accelerated Mobile Pages) generator for Hexo.
MIT License
127 stars 28 forks source link

fix external detection on url prefix with '//' & fix error when img has no src attribute #25

Closed TooBug closed 7 years ago

TooBug commented 7 years ago

Some background:

  1. I use url like '//xxx.com/xxx.jpg' to refer an image, cause this format can work well on both http and https sites.
  2. I wrote a lazy load plugin to defer the loading of images. So there exists no src attribute on img, instead there is a data-src attribute. (This PR does nothing on data-src, just skip the img without src.)
tea3 commented 7 years ago

@TooBug Thank you for your advice. I'm glad that the plug-in has become easier to use.

TooBug commented 7 years ago

Nice to see I’m helping making the ecosystem a little bit better. And hope for the new version on npm. :)

原始邮件 发件人:teanotifications@github.com 收件人:tea3/hexo-generator-amphexo-generator-amp@noreply.github.com 抄送:TooBugi@toobug.net; Mentionmention@noreply.github.com 发送时间:2017年5月9日(周二) 15:35 主题:Re: [tea3/hexo-generator-amp] fix external detection on url prefixwith '//' fix error when img has no src attribute (#25)

@TooBug Thank you for your advice. I'm glad that the plug-in has become easier to use. — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

tea3 commented 7 years ago

@TooBug Updated npm version. please update this plugin.