2-1 What is Polymer? 什么是Polymer?

2015-12-17  本文已影响100人  1bdd9a4a74a2

layout: default
type: start
shortname: Docs
title: What is Polymer?
subtitle: Get started

The {{site.project_title}} library is designed to make it easier and faster
for developers to create great, reusable components for the modern web.

Custom elements extend the web

HTML provides a set of built-in elements like <button>, <form> and
<table>. Each element has its own API of attributes, properties, methods, and
events. Each element has built-in styling, as well as style properties you can
override using CSS.

Anyone can use these elements to build a simple web page. But they're
limited. To build something as simple as a set of tabs, you need HTML
plus CSS and usually a script, too.

With custom elements, you can extend the vocabulary of HTML with your own elements.
Elements that provide sophisticated UI. Elements that are as easy to use as <select>:

<my-tabstrip>
  <my-tab>
    Home
  </my-tab>
  <my-tab>
    Services
  </my-tab>
  <my-tab>
    Contact Us
  </my-tab>
<my-tabstrip>

Is {{site.project_title}} web components? Is it elements?

{{site.project_title}} isn't either of those things. {{site.project_title}} is built on top of the web components standards and it helps you build your own custom elements:


Get some elements

The {{site.project_title}} team has written collections of elements that you can use
in your apps. You can find them on the Element catalog.

Write your own

Interested in using the {{site.project_title}} library to build your own elements?

Take a quick tour of the features:

<p>
<a href="../start/quick-tour.html">
<paper-button raised><core-icon icon="arrow-forward"></core-icon>Quick tour</paper-button>
</a>
</p>

Or jump straight to:

<p>
<a href="../devguide/feature-overview.html">
<paper-button raised><core-icon icon="arrow-forward"></core-icon>Developer guide</paper-button>
</a>
</p>

上一篇下一篇

猜你喜欢

热点阅读