Initial commit
This commit is contained in:
commit
4580c5fb94
11
.editorconfig
Normal file
11
.editorconfig
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# editorconfig.org
|
||||||
|
# editorconfig is a unified configuration file that all editors can take
|
||||||
|
# into account
|
||||||
|
root = true
|
||||||
|
|
||||||
|
[*]
|
||||||
|
charset = utf-8
|
||||||
|
end_of_line = lf
|
||||||
|
trim_trailing_whitespace = true
|
||||||
|
indent_style = space
|
||||||
|
indent_size = 2
|
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
dist/
|
||||||
|
node_modules/
|
5
app/App.vue
Normal file
5
app/App.vue
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
<template>
|
||||||
|
<div class="rsvp-app" role="application">
|
||||||
|
<router-view></router-view>
|
||||||
|
</div>
|
||||||
|
</template>
|
25
app/index.js
Normal file
25
app/index.js
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
// NPM imports
|
||||||
|
import Vue from 'vue'
|
||||||
|
import VueRouter from 'vue-router'
|
||||||
|
|
||||||
|
// Local imports
|
||||||
|
import App from './App.vue'
|
||||||
|
import routes from './routes'
|
||||||
|
|
||||||
|
// Initialize Vue
|
||||||
|
Vue.use(VueRouter)
|
||||||
|
|
||||||
|
// Initialize router
|
||||||
|
const router = new VueRouter({
|
||||||
|
routes
|
||||||
|
})
|
||||||
|
|
||||||
|
// Initialize application
|
||||||
|
document.addEventListener('DOMContentLoaded', () => {
|
||||||
|
new Vue({
|
||||||
|
el: '[role=application]',
|
||||||
|
render: h => h(App),
|
||||||
|
router
|
||||||
|
})
|
||||||
|
console.log('App has been initialized.')
|
||||||
|
})
|
12
app/routes.js
Normal file
12
app/routes.js
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
import { publicView, dashboardView } from './views';
|
||||||
|
|
||||||
|
export default [
|
||||||
|
{
|
||||||
|
path: '/',
|
||||||
|
component: publicView
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/dashboard',
|
||||||
|
component: dashboardView
|
||||||
|
}
|
||||||
|
]
|
3
app/views/dashboardView.vue
Normal file
3
app/views/dashboardView.vue
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<template>
|
||||||
|
<div><p>Hello world 2</p></div>
|
||||||
|
</template>
|
4
app/views/index.js
Normal file
4
app/views/index.js
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
import publicView from './publicView.vue'
|
||||||
|
import dashboardView from './dashboardView.vue'
|
||||||
|
|
||||||
|
export { publicView, dashboardView }
|
5
app/views/publicView.vue
Normal file
5
app/views/publicView.vue
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<p>Hello world</p>
|
||||||
|
</div>
|
||||||
|
</template>
|
15
index.html
Normal file
15
index.html
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<title>RSVP</title>
|
||||||
|
<meta name="mobile-web-app-capable" content="yes">
|
||||||
|
<meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, minimal-ui">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<div role="application"></div>
|
||||||
|
|
||||||
|
<script src="dist/commons.bundle.js"></script>
|
||||||
|
<script src="dist/app.bundle.js"></script>
|
||||||
|
</body>
|
||||||
|
</html>
|
45
package.json
Normal file
45
package.json
Normal file
@ -0,0 +1,45 @@
|
|||||||
|
{
|
||||||
|
"name": "RSVP",
|
||||||
|
"version": "",
|
||||||
|
"cozy-type": "static",
|
||||||
|
"cozy-displayName": "RSVP",
|
||||||
|
"cozy-color": "",
|
||||||
|
"description": "",
|
||||||
|
"license": "",
|
||||||
|
"repository": {
|
||||||
|
"type": "git",
|
||||||
|
"url": ""
|
||||||
|
},
|
||||||
|
"icon-path": "",
|
||||||
|
"cozy-permissions": {
|
||||||
|
"event": {
|
||||||
|
"description": "Needed to hide conflicting time slots from the time slot selection."
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"scripts": {
|
||||||
|
"build:prod": "cross-env NODE_ENV=production webpack -p",
|
||||||
|
"build:dev": "cross-env NODE_ENV=development webpack",
|
||||||
|
"lint": "standard 'app/**/*.js' 'webpack.config.js'",
|
||||||
|
"clean": "rimraf dist/*"
|
||||||
|
},
|
||||||
|
"contributors": [
|
||||||
|
"Phyks (Lucas Verney)"
|
||||||
|
],
|
||||||
|
"dependencies": {
|
||||||
|
"vue": "^2.0.3",
|
||||||
|
"vue-router": "^2.0.1"
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"autoprefixer": "^6.5.1",
|
||||||
|
"babel-core": "^6.18.2",
|
||||||
|
"babel-loader": "^6.2.7",
|
||||||
|
"babel-preset-es2015": "^6.18.0",
|
||||||
|
"cross-env": "^3.1.3",
|
||||||
|
"css-loader": "^0.25.0",
|
||||||
|
"debug-loader": "0.0.1",
|
||||||
|
"rimraf": "^2.5.4",
|
||||||
|
"standard": "^8.5.0",
|
||||||
|
"vue-loader": "^9.7.0",
|
||||||
|
"webpack": "^1.13.3"
|
||||||
|
}
|
||||||
|
}
|
42
webpack.config.js
Normal file
42
webpack.config.js
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
'use strict'
|
||||||
|
|
||||||
|
const path = require('path')
|
||||||
|
const webpack = require('webpack')
|
||||||
|
|
||||||
|
module.exports = {
|
||||||
|
context: path.join(__dirname, 'app'),
|
||||||
|
entry: {
|
||||||
|
app: './index.js'
|
||||||
|
},
|
||||||
|
output: {
|
||||||
|
path: path.join(__dirname, 'dist'),
|
||||||
|
filename: '[name].bundle.js'
|
||||||
|
},
|
||||||
|
module: {
|
||||||
|
loaders: [
|
||||||
|
{
|
||||||
|
test: /\.js$/,
|
||||||
|
exclude: /node_modules/,
|
||||||
|
loader: 'babel',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
test: /\.vue$/,
|
||||||
|
loader: 'vue'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
vue: {
|
||||||
|
postcss: [
|
||||||
|
require('autoprefixer')({
|
||||||
|
browsers: ['last 3 versions']
|
||||||
|
})
|
||||||
|
]
|
||||||
|
},
|
||||||
|
plugins: [
|
||||||
|
new webpack.optimize.CommonsChunkPlugin({
|
||||||
|
name: 'commons',
|
||||||
|
filename: 'commons.bundle.js',
|
||||||
|
minChunks: 2
|
||||||
|
})
|
||||||
|
]
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user