-
Notifications
You must be signed in to change notification settings - Fork 84
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
2.0 preview + prpl server tests #141
Conversation
polymer.json
Outdated
"builds": [ | ||
{ | ||
"preset": "es5-bundled", | ||
"basePath": true |
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.
Adding "basePath": true
will make the build not working on a standard file server (e.g. polymer serve build/es6-unbundled). See this comment: Polymer/prpl-server#24 (comment)
In Shop @keanulee has another branch which contains all the changes needed for deploying to prpl-server.
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.
For Shop we merged the 2.0 changes to master, but kept the prpl-server-specifc changes in a branch, which will not be merged to master for now.
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.
Oh in that case, those changes are already in #136. Should I merge that branch?
sw-precache-config.js
Outdated
@@ -1,11 +1,9 @@ | |||
module.exports = { | |||
staticFileGlobs: [ | |||
'/manifest.json', | |||
'/bower_components/webcomponentsjs/webcomponents-lite.min.js', | |||
'/bower_components/webcomponentsjs/*.js', |
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.
I know you didn't do that but do you mind updating this to only have '/bower_components/webcomponentsjs/webcomponents-loader.js',
and use runtimeCache for other polyfill files. See how we did that in Shop: https://github.com/Polymer/shop/blob/app-engine-node/sw-precache-config.js#L5
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.
Oh! I'm going to do the same in the PSK: Polymer/polymer-starter-kit#1066
About the index.html
, should it be in staticFileGlobs
or in navigateFallback
? Or in both? Or in none?
- news: in none.
- shop: in
staticFileGlobs
. - polymer-starter-kit: in
staticFileGlobs
&navigateFallback
.
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.
Technically, index.html
is not needed in either staticFileGlobs
or navigateFallback
since polymer build
will already do so. Including it is a no-op.
README.md
Outdated
|
||
## Deploy to Google App Engine | ||
|
||
gcloud app deploy build/bundled/app.yaml --project [YOUR_PROJECT_ID] | ||
gcloud app deploy build/es6-unbundled/app.yaml --project [YOUR_PROJECT_ID] |
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.
Maybe update the README to include es6-bundled
build. See the README in Shop: https://github.com/Polymer/shop/blob/master/README.md
sw-precache-config.js
Outdated
@@ -1,11 +1,9 @@ | |||
module.exports = { | |||
staticFileGlobs: [ | |||
'/manifest.json', |
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.
Should not routes be relative? Also in the manifest.json
.
Like the PSK: Polymer/polymer-starter-kit#1008
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.
It doesn't seem to make a difference, as polymer build
will remove the leading slash (so it's always relative to the specific build, like es6-bundled/
).
@notwaldorf Let's update the |
@keanulee thanks! Should be nice if we also sync the |
src/news-data.html
Outdated
@@ -97,7 +97,7 @@ | |||
this._setFailure(false); | |||
return; | |||
} | |||
this._fetch('/data/articles/' + article.id + '.html', | |||
this._fetch('data/articles/' + article.id + '.html', |
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.
This should be part of the master, right?
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.
Yes. Updated and re-merged
@@ -0,0 +1,61 @@ | |||
/** |
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.
Should the polymer-build
do this at some point?
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.
It should, yeah. I think we're still discussing what the syntax should look like
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.
Thanks Monica!
a6a9756
to
3fc4342
Compare
You guysssssss I don't remember what's happening in this PR. Should we merge it? Should we not? @frankiefu @keanulee |
@keanulee has already made a branch for the prpl-server config stuffs in here: https://github.com/Polymer/news/tree/prpl-node-server. |
Yeah, we're not merging server config stuff into |
Added prpl-server config and stuff.
This also includes the
2.0-preview
branch changes because I was lazy, but if you want to review that branch separately and then do 2 merges, we can totally do that too.@frankiefu @keanulee 👀 🙏