This is my first commit

master
androiddrew 7 years ago
commit bd90b2f5bc

@ -0,0 +1,3 @@
{
"presets": ["env"]
}

2
.gitignore vendored

@ -0,0 +1,2 @@
dist/
node_modules/

@ -0,0 +1,14 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title></title>
</head>
<body>
<div @click="printDirp" id="app">
{{ message }}
</div>
<script type="text/javascript" src="dist/bundle.js">
</script>
</body>
</html>

7820
package-lock.json generated

File diff suppressed because it is too large Load Diff

@ -0,0 +1,21 @@
{
"name": "revue",
"version": "1.0.0",
"description": "Reviewing Vue concepts",
"main": "app.js",
"dependencies": {
"vue": "^2.5.16"
},
"devDependencies": {
"babel-core": "^6.26.0",
"babel-loader": "^7.1.4",
"babel-preset-env": "^1.6.1",
"webpack": "^4.2.0",
"webpack-cli": "^2.0.13"
},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "drew@androiddrew.com",
"license": "MIT"
}

@ -0,0 +1,23 @@
import Vue from 'vue'
const app = new Vue({
el: '#app',
data() {
return {
message: "Hello Vue",
users: []
}
},
created() {
console.log("Hey I just got created. Happy birthday to me!")
fetch('https://jsonplaceholder.typicode.com/users/')
.then(response => response.json())
.then(json => this.users = json)
},
methods: {
printDirp(){
console.log("Dirp")
}
}
})

@ -0,0 +1,22 @@
module.exports = {
// entry: './app.js',
entry: './src/app.js',
mode: 'development',
output: {
filename: 'bundle.js'
},
module: {
rules: [
{ test: /\.js$/, exclude: /node_modules/, loader: "babel-loader" }
]
},
// because we aren't using vue loader
resolve: {
alias: {
vue: 'vue/dist/vue.js'
}
}
}
Loading…
Cancel
Save