-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update README for 3.x #5218
Update README for 3.x #5218
Conversation
README.md
Outdated
|
||
**To evaluate Polymer 2.0**, please point your bower at the latest `2.0.0` tag for polymer, and be sure load to the `webcomponentsjs/webcomponents-lite.js` or `webcomponentsjs/webcomponents-loader.js` polyfills from the latest `v1.0.0` tag of [`webcomponentsjs`](https://github.com/webcomponents/webcomponentsjs). | ||
* Runs in browsers with [Javascript Modules](https://caniuse.com/#search=modules): [JSBin](https://jsbin.com/wuxejiz/edit?html,output), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
JavaScript (casing), here and everywhere
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
README.md
Outdated
1. Create a class that extends `PolymerElement`. | ||
1. Implement a static `properties` getter that describes the element's public property/attribute API | ||
(these automatically become observed attributes). | ||
1. Then implement a `template` getter that reutrns an `HTMLTemplateElement` describing the element's rendering, including encapsulated styling and any property bindings. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
reutrns
-> returns
README.md
Outdated
|
||
customElements.define(MyBoundNamecard.is, MyBoundNamecard); | ||
``` | ||
By being based on the Web Components API's built in the browser (or [polyfilled](https://github.com/webcomponents/webcomponentsjs) where needed), elements built with Polymer are: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Web Components API's
should not have possessive
README.md
Outdated
* Interoperable at the browser level | ||
* Built from the platform up | ||
* Self-contained | ||
* Don't require an overarching framework - are interoperable across frameworks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* Don't require an overarching framework - are interoperable across frameworks
->
* Interoperable across frameworks
README.md
Outdated
|
||
} | ||
Polymer 3.0 is now released to stable, and introduces a major change to how Polymer is distributed: from HTML Imports on bower, to JS modules on npm. Otherwise, the API is virtually 100% backward compatible with Polymer 2.0 (the only changes are removing API's related to HTML Imports like `importHref`, and converting Polymer's API to be module-based rather than globals-based). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
from HTML Imports on bower
-> from HTML Imports on Bower
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
virtually 100%
maybe -> almost entirely
or something? Or remove it
README.md
Outdated
|
||
} | ||
Polymer 3.0 is now released to stable, and introduces a major change to how Polymer is distributed: from HTML Imports on bower, to JS modules on npm. Otherwise, the API is virtually 100% backward compatible with Polymer 2.0 (the only changes are removing API's related to HTML Imports like `importHref`, and converting Polymer's API to be module-based rather than globals-based). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
API's
-> APIs
README.md
Outdated
<!-- using the element --> | ||
<my-styled-namecard my-name="Jesse"></my-styled-namecard> | ||
``` | ||
Migrating to Polyme 3.0 by hand is mostly mechanical: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Polyme 3.0
-> Polymer 3.0
README.md
Outdated
``` | ||
Migrating to Polyme 3.0 by hand is mostly mechanical: | ||
* Components should be defined in JS modules instead of in HTML | ||
* Templates should be encoded in JS modules using a `static get template()` getter on PolymerElement subclasses using the `html` tagged template literal function (which parses `HTMLTemplateElement`'s out of strings in JS) rather than using `<template>` elements in a `<dom-module>` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
HTMLTemplateElement
's -> HTMLTemplateElement
s
README.md
Outdated
Migrating to Polyme 3.0 by hand is mostly mechanical: | ||
* Components should be defined in JS modules instead of in HTML | ||
* Templates should be encoded in JS modules using a `static get template()` getter on PolymerElement subclasses using the `html` tagged template literal function (which parses `HTMLTemplateElement`'s out of strings in JS) rather than using `<template>` elements in a `<dom-module>` | ||
* All dependencies should be imported JS module imports rather than from HTML Imports. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
delete from
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nitpicks :)
Update README for 3.x