Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,12 @@
"ajax"
],
"dependencies": {
"iron-component-page": "PolymerElements/iron-component-page#^1.0.0",
"polymer": "polymer/polymer#^v1.2.0",
"iron-icons": "PolymerElements/iron-icons#^1.0.0",
"iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0",
"iron-ajax": "PolymerElements/iron-ajax#^1.0.0",
"paper-button": "PolymerElements/paper-button#^1.0.0"
"paper-button": "PolymerElements/paper-button#^1.0.0",
"webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0"
}
}
5 changes: 5 additions & 0 deletions demo/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
<title>Paper-carousel demo</title>
<link rel="import" href="../../polymer/polymer.html">
<link rel="import" href="../../iron-icons/iron-icons.html">
<link rel="import" href="../../iron-resizable-behavior/iron-resizable-behavior.html">
<link rel="import" href="../../iron-ajax/iron-ajax.html">
<link rel="import" href="../../paper-button/paper-button.html">
<link rel="import" href="../paper-lightbox.html">
<link href="https://fonts.googleapis.com/css?family=Open+Sans:300,300italic,600,400,400italic,800" rel="stylesheet" type="text/css">
<style>
Expand Down
17 changes: 17 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<!doctype html>
<html>
<head>

<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">

<script src="../webcomponentsjs/webcomponents-lite.js"></script>
<link rel="import" href="../iron-component-page/iron-component-page.html">

</head>
<body>

<iron-component-page></iron-component-page>

</body>
</html>
17 changes: 11 additions & 6 deletions tools/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ var pug = require('pug');
var chalk = require('chalk');
var sass = require('gulp-sass');
var cleanCSS = require('gulp-clean-css');
var gls = require('gulp-live-server');

var AUTOPREFIXER_BROWSERS = [
'ie >= 10',
Expand Down Expand Up @@ -87,16 +88,20 @@ var coffeeCompile = function(path) {
// Watch files for changes & reload
gulp.task('serve', function() {
// BrowserSync config
browserSync.init({
port: 4000,
var server = gls('serverConfig.js');
server.start().then(function(result) {
console.log('Server exited with result:', result);
process.exit(result.code);
});
browserSync.init({
proxy: 'localhost:4000',
port: 8888,
logPrefix: 'localhost',
notify: true,
logLevel: 'silent',
startPath: '/paper-lightbox/demo/',
server: {
baseDir: "../../"
}
startPath: '/paper-lightbox/demo/'
});
$.watch('serverConfig.js', server.start.bind(server)); //restart my server

// Changes fire reload
$.watch(['../source/*.html', '!../dev/client/elements/**/*.html'], reload);
Expand Down
1 change: 1 addition & 0 deletions tools/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"gulp-uglify": "^2.0.0",
"gulp-watch": "^4.3.8",
"pug": "^2.0.0-beta3",
"gulp-live-server": "0.0.30",
"web-component-tester": "^4.0.0"
},
"scripts": {
Expand Down
16 changes: 16 additions & 0 deletions tools/serverConfig.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
var path = require('path');
var express = require( 'express' );
var app = express();
var url = path.join(__dirname, '../');
var request = require('request');

// Configuración de rutas estrictas para diferenciar si llevan o no slash (/) al final
app.set('strict routing', true);

// Definición de carpetas públicas
app.use( '/:project/demo', express.static('../demo') );
app.use( '/:project', express.static('../') );
app.use( '/', express.static('../bower_components') );

// Inicialización del servidor a través del puerto especificado
app.listen(4000);