diff --git a/.eslintrc.json b/.eslintrc.json new file mode 100644 index 0000000..ce13b20 --- /dev/null +++ b/.eslintrc.json @@ -0,0 +1,16 @@ +{ + "extends": ["eslint:recommended", "google"], + "env": { + "browser": true + }, + "plugins": [ + "html" + ], + "rules": { + "no-var": "off", + "new-cap": ["error", { "capIsNewExceptions": ["Polymer"] }] + }, + "globals": { + "Polymer": true + } +} diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..2125666 --- /dev/null +++ b/.gitattributes @@ -0,0 +1 @@ +* text=auto \ No newline at end of file diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md new file mode 100644 index 0000000..38f6726 --- /dev/null +++ b/.github/ISSUE_TEMPLATE.md @@ -0,0 +1,33 @@ + +### Description + + +### Expected outcome + + + +### Actual outcome + + + +### Live Demo + + +### Steps to reproduce + + + +### Browsers Affected + +- [ ] Chrome +- [ ] Firefox +- [ ] Safari 9 +- [ ] Safari 8 +- [ ] Safari 7 +- [ ] Edge +- [ ] IE 11 +- [ ] IE 10 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..f42fcbc --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +bower_components/ +build/ +node_modules/ +yarn.lock diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..280e8ec --- /dev/null +++ b/.travis.yml @@ -0,0 +1,19 @@ +language: node_js +sudo: required +dist: trusty +addons: + firefox: latest + apt: + sources: + - google-chrome + packages: + - google-chrome-stable +node_js: + - '6' + - '5' + - '4' +before_script: + - npm install -g bower polymer-cli + - bower install +script: + - xvfb-run npm test diff --git a/README.md b/README.md new file mode 100644 index 0000000..541782d --- /dev/null +++ b/README.md @@ -0,0 +1,56 @@ +# JVMDeveloper.id Website + +Website for JVMDeveloper.id. Readme will be updated accordingly. + +## Pre Requirement + +You must have: + +* NodeJS version `6.9.0+` +* Bower +* Polymer-CLI + +Download NodeJS at [nodejs.org](https://nodejs.org). Bower and polymer-cli +can be install with: + +``` +$ npm install -g bower +$ npm install -g polymer-cli +``` + +### Running Website Locally + +This command serves the app at `http://localhost:8080` and provides basic URL +routing for the app: + + polymer serve --open + +### Build + +This command performs HTML, CSS, and JS minification on the application +dependencies, and generates a service-worker.js file with code to pre-cache the +dependencies based on the entrypoint and fragments specified in `polymer.json`. +The minified files are output to the `build/unbundled` folder, and are suitable +for serving from a HTTP/2+Push compatible server. + +In addition the command also creates a fallback `build/bundled` folder, +generated using fragment bundling, suitable for serving from non +H2/push-compatible servers or to clients that do not support H2/Push. + + polymer build + +### Preview the build + +This command serves the minified version of the app at `http://localhost:8080` +in an unbundled state, as it would be served by a push-compatible server: + + polymer serve build/unbundled + +This command serves the minified version of the app at `http://localhost:8080` +generated using fragment bundling: + + polymer serve build/bundled + +### Finalize Build for Deployment + +TBD (build script needs to be created) diff --git a/bower.json b/bower.json new file mode 100644 index 0000000..645d83e --- /dev/null +++ b/bower.json @@ -0,0 +1,26 @@ +{ + "name": "polymer-starter-kit", + "authors": [ + "The Polymer Authors" + ], + "license": "https://polymer.github.io/LICENSE.txt", + "dependencies": { + "app-layout": "PolymerElements/app-layout#^0.10.0", + "app-route": "PolymerElements/app-route#^0.9.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-iconset-svg": "PolymerElements/iron-iconset-svg#^1.0.0", + "iron-localstorage": "PolymerElements/iron-localstorage#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0", + "iron-pages": "PolymerElements/iron-pages#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.1.4", + "polymer": "Polymer/polymer#^1.6.0", + "paper-card": "PolymerElements/paper-card#^1.1.4", + "iron-icons": "PolymerElements/iron-icons#^1.2.0" + }, + "devDependencies": { + "web-component-tester": "^4.0.0" + }, + "private": true +} diff --git a/images/favicon.ico b/images/favicon.ico new file mode 100644 index 0000000..9cd897e Binary files /dev/null and b/images/favicon.ico differ diff --git a/images/manifest/icon-144x144.png b/images/manifest/icon-144x144.png new file mode 100644 index 0000000..c09f0ce Binary files /dev/null and b/images/manifest/icon-144x144.png differ diff --git a/images/manifest/icon-192x192.png b/images/manifest/icon-192x192.png new file mode 100644 index 0000000..e74d22e Binary files /dev/null and b/images/manifest/icon-192x192.png differ diff --git a/images/manifest/icon-48x48.png b/images/manifest/icon-48x48.png new file mode 100644 index 0000000..15bb11e Binary files /dev/null and b/images/manifest/icon-48x48.png differ diff --git a/images/manifest/icon-512x512.png b/images/manifest/icon-512x512.png new file mode 100644 index 0000000..1f8053f Binary files /dev/null and b/images/manifest/icon-512x512.png differ diff --git a/images/manifest/icon-72x72.png b/images/manifest/icon-72x72.png new file mode 100644 index 0000000..c0af865 Binary files /dev/null and b/images/manifest/icon-72x72.png differ diff --git a/images/manifest/icon-96x96.png b/images/manifest/icon-96x96.png new file mode 100644 index 0000000..712a605 Binary files /dev/null and b/images/manifest/icon-96x96.png differ diff --git a/index.html b/index.html new file mode 100644 index 0000000..f99b16e --- /dev/null +++ b/index.html @@ -0,0 +1,102 @@ + + + + + + + + My App + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/manifest.json b/manifest.json new file mode 100644 index 0000000..1c787ff --- /dev/null +++ b/manifest.json @@ -0,0 +1,20 @@ +{ + "name": "My App", + "short_name": "My App", + "start_url": "/?homescreen=1", + "display": "standalone", + "theme_color": "#3f51b5", + "background_color": "#3f51b5", + "icons": [ + { + "src": "images/manifest/icon-192x192.png", + "sizes": "192x192", + "type": "image/png" + }, + { + "src": "images/manifest/icon-512x512.png", + "sizes": "512x512", + "type": "image/png" + } + ] +} diff --git a/package.json b/package.json new file mode 100644 index 0000000..2ad9906 --- /dev/null +++ b/package.json @@ -0,0 +1,13 @@ +{ + "name": "polymer-starter-kit", + "license": "BSD-3-Clause", + "devDependencies": { + "eslint": "^3.12.0", + "eslint-config-google": "^0.7.1", + "eslint-plugin-html": "^1.7.0" + }, + "scripts": { + "lint": "eslint . --ext js,html --ignore-path .gitignore", + "test": "npm run lint && polymer test" + } +} diff --git a/polymer.json b/polymer.json new file mode 100644 index 0000000..98257c7 --- /dev/null +++ b/polymer.json @@ -0,0 +1,16 @@ +{ + "entrypoint": "index.html", + "shell": "src/templates/jvm-developer-id.html", + "fragments": [ + "src/about.html" + ], + "sourceGlobs": [ + "src/**/*", + "images/**/*", + "bower.json" + ], + "includeDependencies": [ + "manifest.json", + "bower_components/webcomponentsjs/webcomponents-lite.min.js" + ] +} \ No newline at end of file diff --git a/service-worker.js b/service-worker.js new file mode 100644 index 0000000..93e9d49 --- /dev/null +++ b/service-worker.js @@ -0,0 +1,15 @@ +/** + * @license + * Copyright (c) 2016 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 + */ + +/* eslint no-console: ["error", { allow: ["info"] }] */ + +console.info( + 'Service worker disabled for development, will be generated at build time.' +); diff --git a/src/404-page.html b/src/404-page.html new file mode 100644 index 0000000..1559f1a --- /dev/null +++ b/src/404-page.html @@ -0,0 +1,20 @@ + + + + + + + \ No newline at end of file diff --git a/src/about-page.html b/src/about-page.html new file mode 100644 index 0000000..41ac6c9 --- /dev/null +++ b/src/about-page.html @@ -0,0 +1,41 @@ + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/templates/jvm-developer-id.html b/src/templates/jvm-developer-id.html new file mode 100644 index 0000000..8f885e1 --- /dev/null +++ b/src/templates/jvm-developer-id.html @@ -0,0 +1,91 @@ + + + + + + + + + + + + + + diff --git a/sw-precache-config.js b/sw-precache-config.js new file mode 100644 index 0000000..301bb56 --- /dev/null +++ b/sw-precache-config.js @@ -0,0 +1,20 @@ +/** + * @license + * Copyright (c) 2016 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 + */ + +/* eslint-env node */ + +module.exports = { + staticFileGlobs: [ + '/index.html', + '/manifest.json', + '/bower_components/webcomponentsjs/webcomponents-lite.min.js', + ], + navigateFallback: 'index.html', +}; diff --git a/test/.eslintrc.json b/test/.eslintrc.json new file mode 100644 index 0000000..72c9403 --- /dev/null +++ b/test/.eslintrc.json @@ -0,0 +1,10 @@ +{ + "env": { + "mocha": true + }, + "globals": { + "assert": false, + "fixture": false, + "WCT": false + } +} diff --git a/test/index.html b/test/index.html new file mode 100644 index 0000000..8678e38 --- /dev/null +++ b/test/index.html @@ -0,0 +1,29 @@ + + + + + + + + + Tests + + + + + + + diff --git a/test/my-view1.html b/test/my-view1.html new file mode 100644 index 0000000..bcb7962 --- /dev/null +++ b/test/my-view1.html @@ -0,0 +1,47 @@ + + + + + + + + + my-view1 + + + + + + + + + + + + + + +