Live data from Hacker News

CPP: A Standardized Alternative to AMP

timkadlec.com

41–50 of 97 posts

Re: CPP: A Standardized Alternative to AMP

#41
post #14

I agree with the premise that the amp framework (or any such framework) should be separate from being forced to work with only a specific set of tools, etc. However, it seems to me that what the author is proposing is really just more/better adherence to html/web specs...no? Or perhaps, a few performance-related tweaks to existing html/web specs...I mean, if we all (that is web producers, website managers, content au…

Right now there are a lot of things that specs let you do that will make your page slow, like running a lot of js in the scroll event handler, or just including too much js overall. If you read the current proposal [1] the idea is that the site could make promises not to do various kinds of slow things, and the browser could enforce that.

[1] http://wicg.github.io/ContentPerformancePolicy/

Re: CPP: A Standardized Alternative to AMP

#42
post #4

This was first published last February, and the top comment was from a Googler who's involved with the AMP project: > Love this. Not sure by coincidence, but the AMP team has been playing around with the same thing under literally the same name. We should meet up some time and discuss details. Not sure it would be an alternative, but rather a complementary thing. I wonder what ever came of that.

The spec has been moving along: http://wicg.github.io/ContentPerformancePolicy/

Re: CPP: A Standardized Alternative to AMP

#43

Isn't there a better alternative to an abbreviation that's already widely used in the software engineering context?

Search engines already deal just fine with context. Just type in “cpp language” or “cpp html,” respectively.

I think everyone keeps making name collisions to be a much bigger deal than they are in reality.

Re: CPP: A Standardized Alternative to AMP

#44
post #16
post #3

Just use pure HTML/CSS and the web sites will fly by comparison.

For a single page load, sure. For subsequent page loads you're loading a lot more than necessary (a JS app can fetch just the content that's changed, and without a blank page in between), so a pure HTML and CSS solution is a great deal slower. Plus, if you users have unreliable internet connections then a JS app can use a service worker to cache the entire app to work offline, and only load in new content when possib…

Actually for the first part, there is this protocol called SDCH (https://en.wikipedia.org/wiki/SDCH) that allows a site owner to define a site-global compression dictionary, and each resource then becomes a compressed resource with the dictionary being the former one. It's hard to deploy, but it works: LinkedIn saw an average of 24% additional compression.

For the second part I wonder if browsers could display stale data with some warning saying so; that would solve many problems that happen all the time (refreshing a page after the website came down, ...)

Re: CPP: A Standardized Alternative to AMP

#45

This is very interesting and I don't want to detract from that . However, pointing out that for a (large?) portion of us, CPP means "C Plus Plus" so I was confused for a few seconds.

The name makes perfect sense in context:

> CPP could borrow from the concept and approach of the already existing Content Security Policies (CSP). This means that there would likely be a reporting-only mode that would allow sites to see the impact the policy would have on their pages before applying it live.

Re: CPP: A Standardized Alternative to AMP

#46
post #42
post #4

This was first published last February, and the top comment was from a Googler who's involved with the AMP project: > Love this. Not sure by coincidence, but the AMP team has been playing around with the same thing under literally the same name. We should meet up some time and discuss details. Not sure it would be an alternative, but rather a complementary thing. I wonder what ever came of that.

The spec has been moving along: http://wicg.github.io/ContentPerformancePolicy/

The spec has been split into smaller pieces. The first one that made the most progress is https://wicg.github.io/feature-policy/

Re: CPP: A Standardized Alternative to AMP

#47
post #43

Isn't there a better alternative to an abbreviation that's already widely used in the software engineering context?

Search engines already deal just fine with context. Just type in “cpp language” or “cpp html,” respectively. I think everyone keeps making name collisions to be a much bigger deal than they are in reality.

If it was a minor collision, sure. But CPP is one of the most used programming languages on the planet. I suppose you think we should create standards for C++ and call them JS or RB or py, for short?

Re: CPP: A Standardized Alternative to AMP

#48
post #14

I agree with the premise that the amp framework (or any such framework) should be separate from being forced to work with only a specific set of tools, etc. However, it seems to me that what the author is proposing is really just more/better adherence to html/web specs...no? Or perhaps, a few performance-related tweaks to existing html/web specs...I mean, if we all (that is web producers, website managers, content au…

> However, it seems to me that what the author is proposing is really just more/better adherence to html/web specs...no? Pretty much but buzzwords/PR work, "CPP Compliant" vs "We build stuff properly (for a given value of properly)"

No, there are terrible antipatterns that browsers enable to not break compatibility. A strict performance sensitive mode for web platform (HTML/CSS/JS) is long overdue. AMP is a pretty great solution, and the only issue with it has been the proprietary feeling. The browser support is the cherry on top.

The argument that people will just use best practices out of sheer goodwill or even just basic competence has been thoroughly debunked. No one optimizes for performance if they are not penalized.

Re: CPP: A Standardized Alternative to AMP

#49
post #47
post #43

Earlier quoted context omitted.

Search engines already deal just fine with context. Just type in “cpp language” or “cpp html,” respectively. I think everyone keeps making name collisions to be a much bigger deal than they are in reality.

If it was a minor collision, sure. But CPP is one of the most used programming languages on the planet. I suppose you think we should create standards for C++ and call them JS or RB or py, for short?

If you can always find what you’re looking for for any non-trivial (2 keywords or more) search terms, how is it not a minor collision? “CPP” is not even the name of the language—it’s the file extension.

EDIT: Mostly I’m just annoyed that those useless off-topics about naming keep crowding out actual discussion.

Re: CPP: A Standardized Alternative to AMP

#50
post #49
post #47

Earlier quoted context omitted.

If it was a minor collision, sure. But CPP is one of the most used programming languages on the planet. I suppose you think we should create standards for C++ and call them JS or RB or py, for short?

If you can always find what you’re looking for for any non-trivial (2 keywords or more) search terms, how is it not a minor collision? “CPP” is not even the name of the language—it’s the file extension. EDIT: Mostly I’m just annoyed that those useless off-topics about naming keep crowding out actual discussion.

But CPP is the name of the language!

https://en.wikipedia.org/wiki/C_preprocessor

Post reply on HN