I was able to get this up and running by doing a few things:
Mine was off a little bit based on how I read the instructions. Make sure you check out the subfolders for consistency as well.
Make sure you have a webpack.config.js in your root folder that looks like this: github.com/markjohnson303/vue-todo....
Don't forget the last step of updating index.html to reference bundle.js
I had to make a couple changes to the webpack.config.js that Samuel has in his repo, but this should get you going.
Thanks Mark J. I got error when running 'npm run build'. So I followed your suggestions, checked for file structure and used your webpack.config.js.
I got passed this error. However, when I load the app, add/delete/all work but update function didn't work (.save callback function didn't fire).
So I made this change and it's now working:
todo.save({ function (error, todo) { ... } })
Changed to (removed {})
todo.save( function (error, todo) { ... } )
Based on suggestions on best practice, I also changed file names to lowercase (todo.js, routes.js, config.js) and variable Todo -> todo.
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
I was able to get this up and running by doing a few things:
Mine was off a little bit based on how I read the instructions. Make sure you check out the subfolders for consistency as well.
Make sure you have a webpack.config.js in your root folder that looks like this: github.com/markjohnson303/vue-todo....
Don't forget the last step of updating index.html to reference bundle.js
I had to make a couple changes to the webpack.config.js that Samuel has in his repo, but this should get you going.
Thanks Mark J. I got error when running 'npm run build'. So I followed your suggestions, checked for file structure and used your webpack.config.js.
I got passed this error. However, when I load the app, add/delete/all work but update function didn't work (.save callback function didn't fire).
So I made this change and it's now working:
todo.save({
function (error, todo) {
...
}
})
Changed to (removed {})
todo.save(
function (error, todo) {
...
}
)
Based on suggestions on best practice, I also changed file names to lowercase (todo.js, routes.js, config.js) and variable Todo -> todo.