4 ms·
AMP can be preloaded because it's designed to be preloaded. Regular HTML pages have side effects that can't be accounted for. lern_too_spel is right. That is
by SquareWheel 7y ago
AMP can be preloaded because it's designed to be preloaded. Regular HTML pages have side effects that can't be accounted for.
lern_too_spel is right. That is literally what AMP was built for.
Let's watch as HN downvotes the correction while upvoting the misinformation in the top-comment.
edit: Downvote and flag. Very disappointing.
- ricardobeat 7y agoSide effects such as?
- SquareWheel 7y agoAnything that could be affected by prerender[1]. Analytics and statcounters, but also state changes executed by visiting a page. It'd be quite problematic to load www.example.com/delete-account/confirm, for example. [1] https://www.w3.org/TR/resource-hints/#dfn-prerender https://www.w3.org/TR/resource-hints/#dfn-prerender
- ricardobeat 7y agoYou are right about analytics, but that's an extremely easy problem to solve - simply disregard stats coming from the search engine bot. In fact both Chrome and Safari currently have a prefetch feature that I think is enabled by default, that's clearly not an issue. For state, I don't see the connection to AMP here. RFC 7231 which defines the HTTP protocol specifically states that GET is idempotent, and should not cause any state changes in the server. The majority of servers conform to that, and if they don't, it's a bug with worse consequences than messing up prefetch.
- SquareWheel 7y agoUnfortunately I think you're being a little too optimistic. The reality I've seen is that GET is used for all sorts of things, including state changes and irreversible consequences. Analytics could check for useragent (and probably already does), but it just introduces a lot of noise. Plus the other concern is that it'd be a huge privacy issue to have analytics being triggered just by performing related searches.
- ricardobeat 7y agoSo what’s your take on Chrome and Safari link preload which are in use by the millions at this exact moment?
- joshuamorton 7y agoThat it shouldn't be used on a search engine's results page. Preload within a domain is reasonable. Preload across domains is, imo, a security concern, but maybe acceptable if the domains are trusted. Preloading untrusted, unknown content is a terrible idea.
- BoorishBears 7y agoThis correction does little to refute the original point so...
- SquareWheel 7y agosuperkuh said: >Starting with google: AMP does not actually make loading any faster. Google just uses it's search monopoly to make it seem so. This is a complete misunderstanding of how AMP works. Google isn't abusing a monopoly to make AMP-pages appear artificially faster; they actually are faster. That's because they're safe to preload by design, as lern_too_spel explained already. The monopoly comment makes even less sense when you consider that other search engines do the same, and even host their own AMP caches.
- andy_ppp 7y agoMost people here disagree with you, hence why you’ll be down voted. Would AMP be used if it wasn’t for the news carousel - nope - so Google is definitely using their position to embrace and extend open standards.
- SquareWheel 7y ago>Most people here disagree with you, hence why you’ll be down voted. No doubt. And it's really unfortunate that bias is trumping facts in this case. >Google is definitely using their position to embrace and extend open standards. There's nothing wrong with embracing or extending technologies. WebComponents, in this case. But if you're hinting at a third step then I'm sorry but open-source by definition cannot be extinguished.
- mulmen 7y agoI believe this is a reference to https://en.m.wikipedia.org/wiki/Embrace,_extend,_and_extinguish https://en.m.wikipedia.org/wiki/Embrace,_extend,_and_extingu.... Open source does absolutely nothing to resist this approach.
- 7y ago
- snazz 7y agoIt solves the preloading problem just fine. It then goes on to create a crapton of new problems.
- dang 7y agoYour comment was correctly flagged for breaking the site guidelines. Downvote-baiting is equal parts tedious and supercilious, and is off topic here. https://news.ycombinator.com/newsguidelines.html https://news.ycombinator.com/newsguidelines.html
- SquareWheel 7y agoHi dang, Thanks for your comment. I wasn't trying to bait any downvotes though. I have no desire to be downvoted. I was frustrating that another user was being incorrectly downvoted and ganged up on simply for explaining how something worked, and I was trying to defend them. I tried editing the comment before I went to bed to soften it but HN would not allow me to do so. If that were possible, I don't think we'd be having this chat. Other users in this thread have similarly been flagged simply for explaining how AMP works. I'd ask that you review the other flagged comments in this thread to review if they were done in respect to the site guidelines as well. Thank you.