1-2 Release notes 发行说明

2015-12-21  本文已影响237人  1bdd9a4a74a2

layout: default
type: about
shortname: Docs
title: Release notes
subtitle: About this release


{% include toc.html %}

<style>
.breaking {
color: red;
text-transform: capitalize;
}
</style>

Release 1.2.3 (2015-11-16)

This release fixes the following issues:

Release 1.2.2 (2015-11-12)

This release includes a number of small optimizations affecting startup time.

This release includes the following new features:

This release includes the following bug fixes and improvements:

Release 1.2.1 (2015-10-29)

This release includes the following new features:

This release includes fixes for the following issues:

Release 1.2.0 (2015-10-22)

This release includes the following new features:

Release 1.1.5 (2015-10-08)

This release includes the following new features:

This release fixes the following issues:

Release 1.1.4 (2015-09-25)

This release fixes the following issues:

Web Components polyfill updated to 0.7.13. The latest version of webcomponents-lite.js
fixes an issue that affected SEO of Polymer 1.x apps.
{: .alert .alert-info }

Release 1.1.3 (2015-09-04)

Release 1.1.2 (2015-08-28)

Release 1.1.1 (2015-08-20)

This release fixes a serious regression in Release 1.1 related to shady DOM distribution. Related issues:

Other fixed issues:

Release 1.1.0 (2015-08-13)

Shared style change

This release includes support for a new style sharing mechanism. The new mechanism
should be used in place of <link rel="import" type="css">.

See Shared styles and external stylesheets in
the Developer guide for details.

As a result of these changes, several recommendations are changing:

Fixed issues:

v1.0.9 (2015-08-07)

Release 1.0.8 (2015-07-23)

Release 1.0.7 (2015-07-16)

Release 1.0.6 (2015-07-09)

Fixed issues:

Release 1.0.5 (2015-06-25)

Fixed issues:

Release 1.0.4 (2015-06-17)

Fixed issues:

Documentation updates 10 June 2015

Release 1.0.3

Release 1.0.3 includes the following bug fixes:

Release 1.0.2

Release 1.0.2 includes the following bug fix:

Release 1.0.1

Release 1.0.1 includes the following bug fixes:

Release 1.0

Release 1.0 includes the following bug fixes since 0.9:

Documentation correction

The Migration guide has been updated to reflect that the
iron-flex-layout
custom properties are the recommended replacement for layout attributes in
Release 1.0. The layout classes previously described
in the Migration guide for Releases 0.8 and 0.9 will continue to work for
now, but are deprecated.

Release 0.9

A number of APIs changed between 0.8-rc.2 and 0.9. This section summarizes the changes.

Element registration changes

<span class="breaking">breaking change:</span> Mixins replaced by behaviors

Mixins have been replaced by behaviors, which can define properties, add
lifecycle callbacks, observers, and event listeners.

Specify behaviors using the behaviors array on the prototype:

Polymer({
  is: "enhanced-element",
  behaviors: [CoolBehavior]
});

For details, see Behaviors.

<span class="breaking">breaking change:</span> constructor renamed to factoryImpl

When creating a custom constructor, the configuration function is
renamed from constructor to factoryImpl, to aid compilation tools.

<span class="breaking">breaking change:</span> hostAttributes changes {#host-attributes}

Static attributes defined in hostAttributes can now be overridden from markup.

As a part of this change, the class attribute can no longer be set from
hostAttributes. If you need to set classes on the host, you can do so
imperatively (for example, by calling classList.add from the ready callback).

<span class="breaking">breaking change:</span> Property observer changes

The format for property observers has changed to be more like the format for computed properties:

Before:

observers: {
  'preload src size': 'updateImage'
},

updateImage: function(preload, src, size) {
  // ... do work using dependent values
}

After:

observers: [
  'updateImage(preload, src, size)'
],

updateImage: function(preload, src, size) {
  // ... do work using dependent values
}

Also, property observers are not invoked until all dependent properties are defined.
If the observer is not being invoked, make sure all dependent properties have non-undefined
default values set.

Styling changes

Custom property support

This release includes several enhancements and changes to custom property support:

<span class="breaking">breaking change:</span> x-style renamed to custom-style

The custom-style element replaces the experimental x-style element.

Custom properties and CSS mixins can now be applied inside a custom-style element.

For more details, see Custom element for document styling.

Support for :root selector

Styling now supports the :root pseudo-class
inside custom-style. In the context of a custom-style element, the :root selector lets
you define a custom property that applies to all custom elements. (In 0.8, applying a property to
all custom elements required a more expensive * selector.)

Data binding changes

<span class="breaking">breaking change:</span> Template helper elements no longer experimental

The template helper elements are no longer experimental, and have been renamed:

Nested template support

As of 0.9, nested templates can access their parent's scope. See Nesting dom-repeat templates for details.

<span class="breaking">breaking change:</span> Array mutation methods

In 0.8, an array observer was used to monitor the mutation of arrays, so adding an
item to an array was observed automatically, but changing a value in an array item required
the setPathValue method (now renamed to set).

0.9 replaces the array observers with a set of array mutation methods. For array changes
to be observed by data bindings, computed properties, or observers, you must use the provided
helper methods: push, pop, splice, shift, and unshift. Like set, the first argument
is a string path to the array.

this.push('users', { first: "Stephen", last: "Maturin" });

Gesture support

This release adds limited gesture support. For details, see Gesture events.

Content security policy (CSP) {#csp}

CSP issues in the initial release of 0.8 have been resolved. CSP still requires separate script and
HTML files.

The CSP-specific functions of vulcanize have been
split into a separate utility, crisper. To prepare a site for
deployment in a CSP environment, you can use a command like this:

vulcanize --inline-scripts --inline-css target.html | \\
    crisper --html build.html --js build.js

For more details on the vulcanize arguments, see the README.

Note: The latest versions of vulcanize are not compatible with {{site.project_title}} 0.5.
For 0.5 projects, use vulcanize versions earlier than 1.0. vulcanize 0.7.10 is the latest version
supporting 0.5 projects.
{: .alert .alert-info }

Utility functions

<span class="breaking">breaking change:</span> transform and translate3d API changes

The method signatures for the transform and translate3d utility methods have
changed to match the other utility methods. The node argument is now the last argument,
and is optional. If node is omitted, the methods act on this.

Before:

transform(node, transform);
translate3d(node, x, y, z);

After:

transform(transform, node);
translate3d(x, y, z, node);

<span class="breaking">breaking change:</span> fire API changes

The fire method now takes three arguments:

fire(type, [detail], [options]);

The options object can contain the following properties:

New utilities

The following utility functions were added since 0.8-rc.2 or were missing
from the earlier documentation:

For details, see Utility functions.

Bug fixes

Release 0.9 includes a number of bug fixes. A few notable fixes are listed below.

上一篇下一篇

猜你喜欢

热点阅读