Hacker News new | past | comments | ask | show | jobs | submit | jtwb's comments login

git add -p


This is a failing of CSS, specifically. CSS has extremely limited tools for building a page layout.

See http://www.w3.org/TR/css3-flexbox/ and http://dev.w3.org/csswg/css3-grid-align/


But it doesn't make sense to me- why does presentation need to be separated from content? On pretty much every single page on the internet, layout and presentation are so tightly coupled that it ends up being more of a hassle to maintain a separate style sheet than it is to declare stuff inline.


content and presentation should be separate so that:

- the browsers can cache presentation instead of loading it every time

- presentation only has to be defined once, instead of every time it's used

- presentation can change based on factors like screen size

- accessibility features, like high-contrast themes, are not possible with tightly coupled presentation logic

if your presentation and content are so tightly coupled that it's easier to inline everything, you're doing it wrong.


If you step back you'll realize these are all failures of HTML and the latency of networks that we have to work around, not requirements.

For caching, why do I have to reload a whole page just to change the article part? The HTML 'it's a document' obsession and terrible DOM model that took so long to be updated.

Why don't I define a high level presentation document and then sub-documents? Network latency and the total bizarreness of CSS selector priority.

Screen size. Why can't you dock elements on a page like form based programming language for the last 10/15 years? HTML doesn't have the ability.

And as for accessibility? If accessibility is taking hints from markup about how to present the page, in reality the mark up is tightly coupled to presentation anyway. Accessibility is tightly coupling the markup to the presentation, what it really means is screen readers can format the content nicely without the need for a style sheet.


I also have a few questions to ask which supports separation of content and presentation:

Have you ever worked on a project that used inline styles on almost ever paragraph or heading? If yes, you will instantly know much of a pain it is. If you've ever transferred said content to a totally different design you should be scarred by this experience.

Have you also tried adding a page to a website that uses a table-based layout (the prime example of presentational HTML)? When a modern design is fit onto one of these layouts, adding content becomes a really painful experience.

I can see first hand the benefits of good separation.


I can attest to this. As a client-side developer I can go into detail of how much pain is involved in changing the skin on a site when the original developers did not structure their HTML well, including inline styles all over the place. Plus in many cases it seemed the developers had no idea how HTML actually works creating pages that will never validate causing all kinds of weird side issues from browser to browser.

I have CSS selectors that go five to six levels deep because of tables contained in tables contained in tables with no classes or ids on any elements. Often times those tables in tables is totally unnecessary.

Div > span > table > tr > span > td > span > div

That's not the way to build a web page. My guess? They used Visual Studio for layout as if they were coding a desktop application.


Are you serious?

Don't get me wrong, there is a lot to hate about HTML and CSS. But unless you're working on a 5-page website, separating those two is a blessing. Do you not remember the nightmare of FONT tags?


> Do you not remember the nightmare of FONT tags?

Yes, but that's simply a failure from having no ability to define abstractions.

Separating form/design/layout from content is one possible abstraction boundary, but it's just one arbitrary one, so it's kind of strange that they tried to bake it into the platform instead of making it easier to define whatever abstractions are meaningful for you.


They deliberately don't let you define whatever abstractions are meaningful you, it's called the Principle of Least Power: http://www.w3.org/DesignIssues/Principles.html#PLP

Just explaining that what you consider a "strange" design choice is actually deliberate and carefully thought out, not defending it--for all I know, it might have been carefully reasoned out but the wrong conclusions reached--but the results stand for themselves: a platform that is now synonymous with "the Internet".


or mobile scaling. or changing the design. or changing a detail on EVERY PAGES of your websites (like the font).


> why does presentation need to be separated from content?

You can't think of any instance when you would want to access the content irrespective of the presentation?

Imagine if, instead of HTML and CSS, web pages were delivered as pre-rendered PNGs. Make a list of all the different things that would break. That's why presentation should be separated from content.


This is the exact problem cited in the original post. Why are we designing for hypothetical users when we have actual users to design for?


I'm not really following you. "Make a list of all the different things that would break" - these things are things that are in use today by real people. No hypothetical people involved.


One group that has always been chasing the "holy grail" of separation of content and presentation are big publishers. They want one content source that is controlled by "editors" and then the content can be rendered differently for the different avenues of publication. Maybe a transform of the content is sent to online databases like lexis/nexis or westlaw, or sent to printing press for a book, or sent to the web, or abstracts sent to a bibliography service, etc.

This is why SGML was big in the publishing industry before the web.

It's mostly achievable but there are clearly problem areas such as tables where sometimes the presentation is an integral part of the content.


I agree with you, but the main reason to do this is to keep it it DRY(Don't Repeat Yourself).

Templating systems help with this a lot, but they don't completely get you around being able to add the class 'round' to everything you want to have rounded corners. That's really why you keep things separate, so you can minting a single point of change.


Why? What does the US have to offer to Sweden in return for implementing this legislation by their design?


The US wields all kinds of influence over a nation like Sweden. If the US raised a few barriers to trade with Sweden, it would have a drastic effect on Sweden's economy. Many Swedish industries depend on exporting to the US, and while US citizens could just import similar goods from elsewhere if Swedish goods became more expensive, Swedish businesses would lose a gigantic and wealthy market that they depend on selling to.

I'm sure that Sweden depends on the US as a military ally as well, it provides visas for many Swedish citizens regularly, and much more. At the end of the day, Sweden just needs the US more than the US needs Sweden, and that's why the US can argue from a position of power for its own industries.


I think Sweden might overestimate their dependence on the US. The military threat to Sweden is currently rather low, (and there's always the rest of NATO).

Countries just need to all agree to start ignoring the US. I bet doing so would be a positive gain for economies in the long run.


Ignoring the US effectively means shutting yourself off from the global culture, because like it or not, America's entertainment industries are the biggest in the world. American movies play everywhere. American music is heard everywhere. Last I heard, America is about half of the video and computer games industry. And even the Internet is dominated by America unless you're Chinese or somewhere similarly insular (this site you're on right now? American).

Some examples of things you'll have to boycott to truly ignore America:

• Google

• Bing

• Blekko

• DuckDuckGo

• Facebook

• Macs

• Windows

• iPhone

• iPad

• Android

• MS Office

• Photoshop

• MySQL

• Java

• C#

• Red Hat

• Firefox

• Chrome

• IE

• Safari

• iTunes

• Final Cut

• Premiere

• Avid

• ProTools

• Logic


You don't need to ignore products of American companies to ignore the American government. I'm sure Google or facebook won't stop refusing service to Sweden, no matter what happens in politics. Physical products will still be available through other countries, if you really need them. Of course other products will be probably easier to acquire, hence the boon to friendlier economies.

Furthermore, if countries start doing this en mass, like I'm suggesting they should, one of two things would happen:

1) Companies would move their Corporate HQs outside of the US. Most already have significant resource outside the US (like for instance, their factories..).

2) or, Enough lobbying pressure would be put on the government that the bully-tactic legislation would stop. If other nations stop responding the way that American corporate lobby groups want them to, they will have to change their tactics or suffocate.

"America's entertainment industries are the biggest in the world."

Well that's kind of the point of this discussion isn't it? Just let your people download what they want, and give the US the finger.


Don't forget, there are many reasons why American businesses are so successful. Most of those reasons have nothing to do with government intervention or bully politics. You may disagree, but there's a very strong argument that movies and music of the quality that comes out of America would be impossible without such strong global copyright enforcement. Every time you consume a movie, you're the direct benefactor of a massive global economy and copyright system that can fund content costing tens of millions of dollars to produce and give it to you for $10. If getting everything for free is more important to you, then only consume open source content.

America doesn't want to force Sweden to obey copyrights just because Microsoft needs Swedish business, it does so because Sweden backing pirates sets a standard for the rest of the world that could very easily lead to a global breakdown of copyright law and less high quality content for everybody, whether they can afford it or not.


"here's a very strong argument that movies and music of the quality that comes out of America would be impossible without such strong global copyright enforcement"

And nothing of value was lost...


>Most of those reasons have nothing to do with government intervention or bully politics. //

In the UK I expect a lot of it is to do with mobilisation of GIs in WWII.

>Every time you consume a movie, you're the direct benefactor of a massive global economy and copyright system that can fund content costing tens of millions of dollars to produce and give it to you for $10. //

Well actually it's more like £15 GBP which is >$20 ($25-23 this year, I think being out by a factor of 2 is notable) for some of us.

That aside it's not exactly an efficient process and the capitalist system appears to have no interest in making it more affordable. Why do actors get paid multi-million dollar sums for doing a movie, why do we support this sort of thing through copyright. Yes I know that's not the limit of it, there's much much more to copyright but you picked on big-budget movies.

If the copyright term on a blockbuster movie was 10 years do you think that movies wouldn't be made any more? Absolutely not. There would be more of them IMO with more drive to creativity. Why on Earth do we protect movies to such an extent when inventions are limited to c. 20-25 years.


I think you have it backwards. To not comply with US diplomatic interests doesn't mean the US stops exporting into the country but means that US will make it harder for the country to export to them. The US is a huge factor for every country whose economy is based on export, like Sweden. The reverse is not true: Sweden (or every other small country) is not a crucial market for the US economy, which makes it possible to ignore them as long as they act on their own.


> MySQL

Actually, Mysql is Swedish :P


I bet more than half the products on there came about or have had major contributions from sources outside of America.


No, Oracle is definitely American.


...and MySQL is definitely open source.


In recent years the US Congress has had a lot of success bullying other countries through the use of the banking system. By putting restrictions on the ability of US banks to do business with the target country's banks they can put a lot of stress on financial interests in that country.


Publicly held corporations are greedy by definition. The objective of such a corporation is simply to make as much money for its owners as possible.

Our laws create an environment where intellectual property abuse has proven to be a profitable venture.

The solution is not to redefine corporations as non-greedy entities.


Not necessarily. Generally, the purpose of a corporation is, in fact, to maximize shareholder wealth, but all a corporation is supposed to do is to represent the interests of the shareholders, which do not have to be financially motivated.

In theory, corporations are not solely profit-seeking. In practice, they tend to be.


I'm not sure if this is an Australia-only thing - and I was under the impression that if was far from being so - but here the responsibility to shareholders of a corporation is solely fiscal.

The reasoning behind this is that shareholder needs tend to differ. If shareholders wish to engage in philanthropy, the corporation is not the ideal (shared) vessel for doing so. Instead, individual investors may receive their asset's rent and choose to distribute their earnings as they please; management is employed to run the Corp and not make decisions for the shareholders' philanthropic activities.


Not true. Corporations are supposed to bring long term value to share holders. In many cases we see lawyers go for a quick buck at the cost of a tarnished image, which is very debatable whether that's good long term.


Exactly. Case in point: Google. Imagine if they started pulling stunts like this - the goodwill they depend on would evaporate overnight, the whole "I don't mind Google owning all my data because they aren't evil" balance would become paranoia about everything they touch, and they would lose billions. I believe that Microsoft's myopic focus on short-term profit at the expense of doing the right thing is one of the major causes of it's recent decline towards obscurity.

In today's world of abundant choice, companies have to provide good products AND provide them ethically.

Back on topic, look at what Astrolabe have done - taken something they probably couldn't make much money from anyway, and got the unix-derived world very pissed off with them. Their employees will feel down and it'll be harder to hire, and they'll have to endure snide remarks for years. I know I'd be selling their shares today, if I had any - I don't like investing in jerks.

Instead, they could have come out and said "We're pleased to donate our IP towards this amazingly useful service", and got a pat on the back from the world. And I'm guessing most of their shareholders would have been happy their investment was making the world a better place.


Very well said. And it is important that we help making this a PR disaster for the company, even if we have to be cautious - being it a quite obscure entity, even bad publicity could be useful to them...


> The solution is not to redefine corporations as non-greedy entities.

Wouldn't it be easier to take measures to make undesirable behavior unprofitable than to throw away capitalism?


So true. It just freaks me out how many people don't get this.

The problem is with the broken legal system that needs to get fixed. No I am not happy about Astrolabe doing this stupid stuff, but they are quite clearly the symptom, not the root cause. We need to fix the system instead of crying foul everytime someone uses the broken system to do something that is against societies best interest.

The same is true of the financial system. Everyday I talk to people who complain about the greedy and 'stupid' bankers. Well, they behaved 100% rationally. If you work in a system where you can play 'heads I win, tails you loose' you almost have to do it (otherwise you will be outearned and get fired). The problem is the system that allows this kind of game. That is what needs to get fixed.


> Publicly held corporations are greedy by definition. The objective of such a corporation is simply to make as much money for its owners as possible.

This isn't always true.

The objective of a corporation is defined by the objective of its owners (if the owners are any good). This objective might not necessarily be "to make as much money as possible."

Different corporations have different cultures, and these cultures can define different priorities for the companies.


Using (input channel, output channel, title) to summarize Recipes makes code search a breeze.

Traditionally, code search is done via fulltext indexing of verbose textual function descriptions. ifttt succeeds in using a channel-signature model, not unlike Hoogle's type-signature search, to provide code search without asking authors to write any description at all. Very nice!

http://www.haskell.org/hoogle/?hoogle=%28a+-%3E+b%29+-%3E+a+...


On the contrary, I feel that the large representation of a Recipe conveys a sense of accessibility and simplicity. It says, "this is something you can understand, it will not boggle your mind, stress you out, or confuse you."

Compare this with Yahoo Pipes, which provided a similar service with an interface intimidating to non-technical users.


The drawing requests are the descriptions of other drawings, not generated by the system.


Please add a way to link to these chains! Some of them are quite funny and worth sharing.


+1


After the competition we plan on adding this and other requested features like a better drawing tool and ipad support.


We forget the value of curation.

Why can a boutique shop sell a $50 dress for $200? Taste. One could simply walk into that boutique, confident that 20 minutes later a cute, fashionable and well-fitting dress would be acquired.

Why can top universities charge so much for tuition? Every year, %s University generates a curated list of individuals, and many hiring processes (not to mention ad-hoc interpersonal filtering processes) emphasize individuals in that list. Like boutique shopping, this is an expensive strategy that often excludes superior talent, but is fast.

Is it worth $200,000 to have one's name on that list? Apparently.

Is it worth application fees and an iron publishing agreement to have one's paper published in Nature. Apparently.



I think it comes down to marketing. I did not know YQL offered proxy access to all those APIs.


They don't proxy, they add edges.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: