Updated libraries
the build was successful Details

This commit is contained in:
konrad 2017-11-09 00:19:01 +01:00 committed by kolaente
parent d62e5c9524
commit 0adb9a152a
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
4 changed files with 42 additions and 31 deletions

View File

@ -19,6 +19,7 @@
"style-loader": "^0.19.0",
"vue-hot-reload-api": "^2.2.3",
"vue-html-loader": "^1.2.3",
"vue-template-compiler": "2.5.3",
"vue-loader": "^13.5.0",
"webpack": "^3.8.1",
"webpack-dev-server": "^2.9.4"

View File

@ -1,12 +1,11 @@
<template>
<li><a v-link="'home'">Home</a></li>
<li v-if="!user.authenticated"><a v-link="'login'">Login</a></li>
<li v-if="!user.authenticated"><a v-link="'signup'">Sign Up</a></li>
<li v-if="user.authenticated"><a v-link="'secretquote'">Secret Quote</a></li>
<li v-if="user.authenticated"><a v-link="'login'" @click="logout()">Logout</a></li>
<div>
<p v-if="user.authenticated"><a v-link="'login'" @click="logout()">Logout</a></p>
<p v-else-if="!user.authenticated"><a v-link="'login'">Login</a></p>
<div class="container">
<router-view></router-view>
</div>
</div>
</template>
<script>

View File

@ -1,6 +1,6 @@
<template>
<p v-if="user.authenticated">Logged in</p>
<p v-if="!user.authenticated">not logged in</p>
<p v-else-if="!user.authenticated">not logged in</p>
</template>
<script>

View File

@ -1,27 +1,38 @@
// TODO:
// * EsLint
// * bessere struktur
module.exports = {
// the main entry of our app
entry: ['./src/index.js', './src/auth/index.js'],
// output configuration
output: {
path: __dirname + '/dist/',
publicPath: 'assets/dist/',
filename: 'app.js'
},
// how modules should be transformed
module: {
loaders: [
// process *.vue files using vue-loader
{ test: /\.vue$/, loader: 'vue' },
// process *.js files using babel-loader
// the exclude pattern is important so that we don't
// apply babel transform to all the dependencies!
{ test: /\.js$/, loader: 'babel', exclude: /node_modules/ }
]
},
// configure babel-loader.
// this also applies to the JavaScript inside *.vue files
babel: {
presets: ['es2015'],
plugins: ['transform-runtime']
}
// the main entry of our app
entry: ['./src/index.js', './src/auth/index.js'],
// output configuration
output: {
path: __dirname + '/dist/',
publicPath: 'assets/dist/',
filename: 'app.js'
},
// how modules should be transformed
module: {
rules: [
// process *.vue files using vue-loader
{
test: /\.vue$/,
loader: 'vue-loader'
},
// process *.js files using babel-loader
// the exclude pattern is important so that we don't
// apply babel transform to all the dependencies!
{
test: /\.js$/,
exclude: /(node_modules|bower_components)/,
use: {
loader: 'babel-loader',
/*options: {
presets: ['@babel/preset-env']
}*/
}
}
]
}
}