Skip to content

Commit

Permalink
Merge pull request #448 from Polymer/export-decorated-items
Browse files Browse the repository at this point in the history
Mark @Property props out of renaming
  • Loading branch information
rictic authored Jan 15, 2019
2 parents 08e9c14 + c08b1f0 commit b3d7d9c
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions src/lib/decorators.ts
Original file line number Diff line number Diff line change
Expand Up @@ -128,12 +128,15 @@ const legacyProperty = (options: PropertyDeclaration, proto: Object,
* A property decorator which creates a LitElement property which reflects a
* corresponding attribute value. A `PropertyDeclaration` may optionally be
* supplied to configure property features.
*
* @ExportDecoratedItems
*/
export const property = (options?: PropertyDeclaration) =>
(protoOrDescriptor: Object|ClassElement, name?: PropertyKey): any =>
(name !== undefined)
? legacyProperty(options!, protoOrDescriptor as Object, name)
: standardProperty(options!, protoOrDescriptor as ClassElement);
export function property(options?: PropertyDeclaration) {
return (protoOrDescriptor: Object|ClassElement, name?: PropertyKey): any =>
(name !== undefined) ?
legacyProperty(options!, protoOrDescriptor as Object, name) :
standardProperty(options!, protoOrDescriptor as ClassElement);
}

/**
* A property decorator that converts a class property into a getter that
Expand Down

0 comments on commit b3d7d9c

Please sign in to comment.