I was checking out Google's News Search API. While it's fairly straight forward to implement, one thing I realized is that their samples show some rather poor code. For instance, in the Google News Search "Hello World" example, you'll see that they create a node called "content". After initializing the node, they never do anything with it. I assume that the results returned from the news search would populate the "content" div section.
In another instance within the example, they put a float: left with a style attribute on one of the div tags. That causes the news results to push out because they forget to clear it. Also, it's kinda funny seeing them utilize a style attribute, which is bad coding style. I suppose that the idea here is just a quick and dirty code sample, but I would've liked seeing Google hold themselves up to a higher standard, especially when showing examples.
Also, it would be nice if the APIs have some form of a comment section at the bottom. No wonder Google has problems in the social realm!
Trackbacks: (Trackback URL)