Skip to content

Commit 6c49326

Browse files
committed
update README and lazy-resources.html
1 parent 6cbaeca commit 6c49326

File tree

2 files changed

+33
-13
lines changed

2 files changed

+33
-13
lines changed

README.md

Lines changed: 30 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
##### Prerequisites
66

77
Install [polymer-cli](https://github.com/Polymer/polymer-cli):
8-
(Need at least npm v0.3.0)
98

109
npm install -g polymer-cli
1110

@@ -15,7 +14,7 @@ Install [polymer-cli](https://github.com/Polymer/polymer-cli):
1514
mkdir shop
1615
cd shop
1716
polymer init shop
18-
17+
1918
# Or cloning direct from GitHub
2019
git clone https://github.com/Polymer/shop.git
2120
cd shop
@@ -31,14 +30,38 @@ Install [polymer-cli](https://github.com/Polymer/polymer-cli):
3130

3231
### Build
3332

33+
Build presets provide an easy way to define common build configurations in your `polymer.json` file. There are 2 build presets we put in `polymer.json` file in Shop:
34+
35+
**es5-bundled**
36+
37+
- js: {minify: true, compile: true}
38+
- css: {minify: true}
39+
- html: {minify: true}
40+
- bundle: true
41+
- addServiceWorker: true
42+
- addPushManifest: true
43+
- insertPrefetchLinks: true
44+
45+
**es6-unbundled**
46+
47+
- js: {minify: true, compile: false}
48+
- css: {minify: true}
49+
- html: {minify: true}
50+
- bundle: false
51+
- addServiceWorker: true
52+
- addPushManifest: true
53+
- insertPrefetchLinks: true
54+
55+
Run the command to build the presets:
56+
3457
polymer build
3558

3659
### Test the build
3760

38-
This command serves the minified version of the app in an unbundled state, as it would be served by a push-compatible server:
61+
This command serves the `es5-bundled` build version of the app:
62+
63+
polymer serve build/es5-bundled
3964

40-
polymer serve build/unbundled
41-
42-
This command serves the minified version of the app generated using fragment bundling:
65+
This command serves the `es6-unbundled` build version of the app:
4366

44-
polymer serve build/bundled
67+
polymer serve build/es6-unbundled

src/lazy-resources.html

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,15 @@
99
-->
1010

1111
<!-- shop-app -->
12-
<link rel="import" href="../bower_components/app-layout/app-drawer/app-drawer.html">
13-
<link rel="import" href="../bower_components/paper-icon-button/paper-icon-button.html">
12+
<link rel="import" href="shop-icons.html">
1413
<link rel="import" href="shop-analytics.html">
1514
<link rel="import" href="shop-cart-data.html">
1615
<link rel="import" href="shop-cart-modal.html">
17-
<link rel="import" href="shop-icons.html">
1816
<link rel="import" href="shop-snackbar.html">
1917
<link rel="import" href="shop-tabs.html">
2018
<link rel="import" href="shop-tab.html">
21-
22-
<!-- shop-home -->
19+
<link rel="import" href="../bower_components/paper-icon-button/paper-icon-button.html">
20+
<link rel="import" href="../bower_components/app-layout/app-drawer/app-drawer.html">
2321

2422
<!-- shop-list -->
2523
<!-- shop-detail -->
@@ -31,5 +29,4 @@
3129

3230
<!-- shop-checkout -->
3331
<link rel="import" href="../bower_components/iron-form/iron-form.html">
34-
<link rel="import" href="../bower_components/iron-icon/iron-icon.html">
3532
<link rel="import" href="../bower_components/paper-spinner/paper-spinner-lite.html">

0 commit comments

Comments
 (0)