Welcome to Component Kitchen, a place to learn about the new web components features in HTML that will transform how you create web apps and sites!

The following Staff Reviews look at web components we think are notable: they're good examples to follow, or they solve a common problem, or they're particularly well-designed. We also write posts about other aspects of web components, including things going on here at Component Kitchen. If you're looking for a particular kind of component, have a look in our extensive compontent catalog of all publicly registered web components.

google-map — A simple wrapper for maps and driving directions

Mon Oct 20 2014 08:00:00 GMT+0000 (UTC)

Many companies embed a hard-coded Google Map on their site to show, for example, the location of their office. This component allows you to easily create more dynamic maps. You could, for example, combine this with geo-location to show your user's current location. You can also combine the basic google-map component with the companion google-map-directions to provide driving directions from the user to your store, office, etc.

Dislikes: This component mostly wraps the Google Maps API, which is powerful but rather complex if you're not already familiar with it.

See our full details on google-map

General-purpose web components

Mon Jun 16 2014 08:15:00 GMT+0000 (UTC)

Component Kitchen founder Jan Miksovsky shares some of his recent experience creating some general-purpose components over on his user interface design/development blog at flow|state.

Creating really good general-purpose components entails more work than creating components for a single organization or product. You can find a good list of principles for great general-purpose components on the site for the open source basic-web-components project, which is sponsored by Component Kitchen.

Live demos let people see what a component is all about

Mon May 26 2014 08:00:00 GMT+0000 (UTC)

We recently added live demos to the Component Kitchen site for all components that define a demo. Components with demos are marked on the home page with a "DEMO" indicator, so you can check out all the demos.

We always want to make it as easy as possible to find interesting components, and demos are obviously the quickest way for someone to really understand what a component can do for them. From the beginning of our work on the service, we've wanted to host demos in situ on the pages we build for components. We want to let a user looking for a component to see the demos front and center (without having to link off to another site just to see a demo) so they can quickly find what they're looking for.

As described in our evolving developer documentation, for the time being, you'll need to host the demo at a site you maintain (e.g., a GitHub Pages site for your component repository). You can then include a @demo line in the comments at the top of your component's main source file to indicate where the component is. We've also seen some conventions emerge whereby a component can imply the location of a demo, and we try to detect when one of those conventions is in use as well, but use of the @demo indicator is the clearest way to point to a demo.

We host demos within an iframe, but traditional iframes make it hard to seamlessly incorporate content from another site, and in particular, the page hosting the iframe can't know how tall the framed page is. While it's fine for us to define a default height for a framed demo, we really want demo authors to be able to control how tall the demo is. Some components, for example, are really small, and so it'd be nicer to have the iframe showing the demo be exactly the height it needs to be.

The standard way to securely communicate across a frame boundary is a facility called window.postMessage(). That approach is somewhat cumbersome to use, however. What we really wanted was a way to package that communication up. A web component was, of course, a great way to do that! We've published our solution through our companion of open source project, basic-web-components. There you'll find two components that work together, basic-seamless-iframe, which goes on the framing page, and basic-framed-content, which goes on the framed page. These components cooperatively communicate across the frame boundary so that, among other things, the outer page can correctly adjust the height of the frame.

So, if you'd like to have your demo auto-size when shown on our site, just add the basic-framed-content component to your project, and wrap the contents of your demo in an instance of <basic-framed-content>. The latter won't interfere with anything when someone views the demo on your site, but when someone views your component on Component Kitchen, the demo will communicate its height to the framing page so that the demo looks just right.

Component Kitchen preview launched

Wed Apr 30 2014 22:08:00 GMT+0000 (UTC)

Today we’re excited to publicly announce the launch of a preview edition of our site at http://component.kitchen.

At Component Kitchen, we think web components are fundamentally a great way to create apps and sites that run across an enormous range of desktop and mobile devices. We’re eager to help a mainstream audience learn about this technology, and discover for themselves how this technology is going to amplify their own creative capabilities as designers, developers, writers, students, business people, and more.

Earlier this year, we observed that most of the material and tools related to web components was intended for a fairly experienced technical audience. We feel that, since web components extend what’s possible with plain HTML and CSS, web components is actually fundamentally interesting to a much broader audience: anyone who is comfortable editing HTML. That’s a lot of people!

Additionally, we believe that people creating web components are going to need a range of services to help promote and distribute their components to a broad audience that includes both hardcore developers and people who work at the HTML level.

We’re starting with a few basics:

  • A catalog of components which have publicly registered for use. The preview release is quite basic, but includes some interesting features such as image previews for many components, and an ability to search the catalog.
  • New Web Components RSS feed. Subscribe to learn about new components as soon as they’re registered.
  • A discussion board for talking about web components. There are some other public forums for web components, but they focus on a highly technical audience. Lots of people will want to use components who have never heard of developer hangouts like GitHub or StackOverflow.

We have a number of interesting features ahead:

  • Live, interactive, configurable component demos. You can see an example on the page for the basic-autosize-textarea component. This lets you play with the component and see how its customization options will affect its appearance and behavior.
  • Web component hosting. Many people create HTML in environments like blogging platforms or mainstream web hosting platforms that don’t allow complete control over the site. If that’s you, we want to allow you to still take advantage of web components by hosting the components on Component Kitchen. Again, visit the basic-autosize-textarea component for an example of component hosting. Click the Copy to Clipboard button, then paste the result in any HTML editor or environment. This will paste in the <script> and <link> tags that let you use that component from its hosted location on Component Kitchen.

Our core mission is to help people create great products using web components. While we have many ideas for how we can do that, we’re most interested in hearing from you. If you have questions or suggestions for our site, let us know at @ComponentK on Twitter, or on our discussion board.

This is going to be such an exciting time to work on the web!

« Newer Older »