@polymer/polymer
Advanced tools
Comparing version 2.0.2 to 3.0.0-pre.1
@@ -9,2 +9,3 @@ { | ||
"no-var": "error", | ||
"semi": "error", | ||
"strict": "error", | ||
@@ -11,0 +12,0 @@ "valid-jsdoc": ["error", { |
@@ -27,3 +27,3 @@ { | ||
"devDependencies": { | ||
"web-component-tester": "^v6.0.0-prerelease.10", | ||
"web-component-tester": "^v6.0.0", | ||
"test-fixture": "PolymerElements/test-fixture#3.0.0-rc.1" | ||
@@ -30,0 +30,0 @@ }, |
/** | ||
* @license | ||
* Copyright (c) 2017 The Polymer Project Authors. All rights reserved. | ||
* This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt | ||
* The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt | ||
* The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt | ||
* Code distributed by Google as part of the polymer project is also | ||
* subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt | ||
* | ||
* @fileoverview Externs for Polymer | ||
@@ -10,4 +18,4 @@ * @externs | ||
* @typedef {{ | ||
* type: !Function, | ||
* value: *, | ||
* type: (!Function | undefined), | ||
* readOnly: (boolean | undefined), | ||
@@ -27,14 +35,17 @@ * computed: (string | undefined), | ||
/** | ||
* @typedef {{ | ||
* is: string, | ||
* extends: (string | undefined), | ||
* properties: (!PolymerElementProperties | undefined), | ||
* observers: (!Array<string> | undefined), | ||
* template: (!HTMLTemplateElement | string | undefined), | ||
* hostAttributes: (!Object<string, *> | undefined), | ||
* listeners: (!Object<string, string> | undefined) | ||
* }} | ||
*/ | ||
let PolymerInit; | ||
let PolymerInit = function(){}; | ||
/** @type {string} */ | ||
PolymerInit.prototype.is; | ||
/** @type {(string | undefined)} */ | ||
PolymerInit.prototype.extends; | ||
/** @type {(!PolymerElementProperties | undefined)} */ | ||
PolymerInit.prototype.properties; | ||
/** @type {(!Array<string> | undefined)} */ | ||
PolymerInit.prototype.observers; | ||
/** @type {(!HTMLTemplateElement | string | undefined)} */ | ||
PolymerInit.prototype.template; | ||
/** @type {(!Object<string, *> | undefined)} */ | ||
PolymerInit.prototype.hostAttributes; | ||
/** @type {(!Object<string, string> | undefined)} */ | ||
PolymerInit.prototype.listeners; | ||
@@ -55,3 +66,3 @@ let PolymerElementConstructor = function (){}; | ||
* @param {!PolymerInit} init | ||
* @return {!HTMLElement} | ||
* @return {!function(new:HTMLElement)} | ||
*/ | ||
@@ -89,2 +100,9 @@ function Polymer(init){} | ||
/** @type {PolymerTelemetry} */ | ||
Polymer.telemetry; | ||
Polymer.telemetry; | ||
/** | ||
* @constructor | ||
* @extends {HTMLElement} | ||
* @implements {Polymer_LegacyElementMixin} | ||
*/ | ||
var PolymerElement = Polymer.LegacyElementMixin(); |
/** | ||
* @license | ||
* Copyright (c) 2017 The Polymer Project Authors. All rights reserved. | ||
* This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt | ||
* The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt | ||
* The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt | ||
* Code distributed by Google as part of the polymer project is also | ||
* subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt | ||
* | ||
* @fileoverview Externs for webcomponents polyfills | ||
@@ -3,0 +11,0 @@ * @externs |
@@ -71,2 +71,13 @@ /** | ||
const licenseHeader = | ||
`/** | ||
* @license | ||
* Copyright (c) 2017 The Polymer Project Authors. All rights reserved. | ||
* This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt | ||
* The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt | ||
* The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt | ||
* Code distributed by Google as part of the polymer project is also | ||
* subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt | ||
*/`; | ||
class AddClosureTypeImport extends Transform { | ||
@@ -245,4 +256,4 @@ constructor(entryFileName, typeFileName) { | ||
return genClosure().then((declarations) => { | ||
fs.writeFileSync('externs/closure-types.js', declarations); | ||
fs.writeFileSync('externs/closure-types.js', `${licenseHeader}${declarations}`); | ||
}); | ||
}); |
{ | ||
"name": "@polymer/polymer", | ||
"version": "2.0.2", | ||
"description": "The Polymer library makes it easy to create your own web components. Give your element some markup and properties, and then use it on a site. Polymer provides features like dynamic templates and data binding to reduce the amount of boilerplate you need to write", | ||
"main": "polymer.html", | ||
"directories": { | ||
"doc": "docs", | ||
"test": "test" | ||
}, | ||
"devDependencies": { | ||
"@polymer/gen-closure-declarations": "^0.1.0", | ||
"@webcomponents/shadycss": "^1.0.0", | ||
"@webcomponents/webcomponentsjs": "^1.0.2", | ||
"babel-preset-babili": "^0.1.4", | ||
"del": "^3.0.0", | ||
"dom5": "^2.3.0", | ||
"eslint-plugin-html": "^2.0.1", | ||
"google-closure-compiler": "^20170626.0.0", | ||
"gulp": "^3.9.1", | ||
"gulp-babel": "^6.1.2", | ||
"gulp-eslint": "^3.0.1", | ||
"gulp-if": "^2.0.1", | ||
"gulp-size": "^2.1.0", | ||
"gulp-vulcanize": "^6.0.1", | ||
"lazypipe": "^1.0.1", | ||
"merge-stream": "^1.0.1", | ||
"parse5": "^3.0.2", | ||
"polymer-build": "^1.6.0", | ||
"run-sequence": "^1.1.0", | ||
"through2": "^2.0.0", | ||
"web-component-tester": "^6.0.0-prerelease.4" | ||
}, | ||
"scripts": { | ||
"build": "gulp", | ||
"test": "gulp lint && wct" | ||
}, | ||
"flat": true, | ||
"version": "3.0.0-pre.1", | ||
"contributors": [ | ||
"The Polymer Authors (http://polymer.github.io/AUTHORS.txt)" | ||
], | ||
"repository": { | ||
@@ -41,11 +12,8 @@ "type": "git", | ||
}, | ||
"author": "The Polymer Project Authors", | ||
"license": "BSD-3-Clause", | ||
"bugs": { | ||
"url": "https://github.com/Polymer/polymer/issues" | ||
"license": "http://polymer.github.io/LICENSE.txt", | ||
"dependencies": { | ||
"@webcomponents/shadycss": "^1.0.0", | ||
"@webcomponents/webcomponentsjs": "^1.0.0" | ||
}, | ||
"homepage": "https://github.com/Polymer/polymer", | ||
"publishConfig": { | ||
"access": "public" | ||
} | ||
} | ||
"devDependencies": {} | ||
} |
@@ -7,13 +7,42 @@ # Polymer | ||
```html | ||
<!-- Polyfill Web Components for older browsers --> | ||
<script src="webcomponentsjs/webcomponents-lite.js"></script> | ||
## Polymer 3.0 is an Early Preview! | ||
<!-- Import element --> | ||
<link rel="import" href="google-map.html"> | ||
This is a preview branch of Polymer 3.0, a very early version of Polymer that uses JavaScript modules instead of HTML Imports. It will only work in browsers with module support, like Safari 10.1 and Chrome 61, or via a compiler like Babel, TypeScript or Closure. | ||
<!-- Use element --> | ||
<google-map latitude="37.790" longitude="-122.390"></google-map> | ||
The API is mostly the same as Polymer 2.0, but the documentation has not been updated. | ||
To try Polymer 3.0-preview, use `yarn` to install from `npm: | ||
```sh | ||
> yarn add @polymer/polymer@next --flat | ||
``` | ||
Launch the Polymer devserver in npm mode: | ||
```sh | ||
> polymer serve --npm | ||
``` | ||
Then load Polymer into your element: | ||
```js | ||
import { Element as PolymerElement } from '../@polymer/polymer/polymer-element.js'; | ||
export class MyElement extends PolymerElement { | ||
static get template() { | ||
return ` | ||
<h1>Hello World!</h1> | ||
`; | ||
} | ||
} | ||
customElements.define('my-element, MyElement); | ||
``` | ||
And use it in a page: | ||
```html | ||
<script type="module" src="./my-element.js"></script> | ||
<my-element></my-element> | ||
``` | ||
# Everything below here has not been updated for 3.0-preview | ||
Check out [polymer-project.org](https://www.polymer-project.org) for all of the library documentation, including getting started guides, tutorials, developer reference, and more. | ||
@@ -20,0 +49,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Misc. License Issues
License(Experimental) A package's licensing information has fine-grained problems.
Found 1 instance in 1 package
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
0
16055
549
2376987
2
156
1
1
2
1
+ Added@webcomponents/shadycss@1.11.2(transitive)
+ Added@webcomponents/webcomponentsjs@1.3.3(transitive)