GithubHelp home page GithubHelp logo

rlindskog / vueniverse Goto Github PK

View Code? Open in Web Editor NEW
336.0 27.0 48.0 495 KB

Full stack, user based, PWA, Vue template.

License: MIT License

JavaScript 58.26% Vue 40.16% CSS 1.58%
vue vuejs vuejs2 universal-app isomorphic hot-reload code-splitting webpack webpack2 isomorphic-applications

vueniverse's Introduction

Welcome to Vueniverse!

Vueniverse is a full-stack JavaScript starter project. Some of the features that comes baked in include:
  • PWA by default, 100/100 lighthouse PWA score.
  • Universal es2015 JavaScript. No more context switching between client/server code!
  • A REST API, and full user authentication with JWT, Redis blacklisting, and MongoDB.
  • Client Side routing, Server Side Rendering and Global State Management thanks to Vuejs and Nuxtjs!
  • Abstracted WebPack build process.
  • Universal HMR for a clean development process, thanks to Nuxtjs and BackPack.
  • Ready for deployment with NOW

Live Demo It might take a while to load if it's asleep.

You must have vue-cli installed.

npm install -g vue-cli

Create Project

vue init rlindskog/vueniverse {{ your-project-name }}
cd {{ your-project-name }}
npm install

Start a MongoDB database locally

npm run start-db

Stop the MongoDB database locally

npm run stop-db

Run in development

npm run dev

Build for production

npm run build

Run in production (runs the database and application in a subprocess)

npm run start

Stop production running (stops the database and application)

npm run stop

Start a Redis database locally (use this if you chose the redis session option)

Install

$ wget http://download.redis.io/redis-stable.tar.gz
$ tar xvzf redis-stable.tar.gz
$ cd redis-stable
$ make
$ # wait for it to install...
$ sudo cp src/redis-server /usr/local/bin/
$ sudo cp src/redis-cli /usr/local/bin/

Then run

redis-server

Deploy with NOW

npm install -g now-cli

You will have to make a database else where, I recommend the Atlas free teir. When you do, paste the url to the DB_URL and a random SECRET variable to the secrets.json file.

Also, if you decided to use the Redis option instead of in-memory (highly recommended), then you will have to create a Redis session store else where as well. I recommend the Redis Labs free tier. Once you make your Redis session, add SESSION_HOST, SESSION_PORT, and SESSION_PASSWORD to the secrets.json file.

Then run...

npm run deploy

If you have any problems, please don't hesitate to create an issue!

FUTURE TODO

  • Create an admin interface! (currently working on)
  • Create a few more NPM convenience commands, such as "create-admin-user" and "create-app" (which would create an MVC folder in the API, and add a page on the admin interface).
  • vue-cli option to choose between PostgreSQL and MongoDB (MongoDB currently implemented)
  • vue-cli option to choose between AirBNB and Standard Linting Style.
  • vue-cli option to include unit/e2e tests.

Pull requests welcome!

vueniverse's People

Contributors

prozi avatar rlindskog avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

vueniverse's Issues

UI improvements

  1. Add oauth2 options for sign up.
  2. During sign up there should be an "e-mail verification"-step before completion of sign-up, others hold that e-mails shouldn't be sent, and verification should be done at a later stage (https://designexcellent.com/ux-login-register-password/), I personally prefer it at some point to avoid "identity" theft.
  3. During sign up there shouldn't be a password size limit. (xx/25 on the first password field)
  4. During sign up the retype password field shouldn't remain red when the passwords match
  5. During sign-in there should be error messages for a) account doesn't exist, b) the wrong password for the account since the system only lets you register once with a password, an attacker can test for e-mail accounts, and usernames, registered on the sign in page. Therefore the user who needs to know their user name (I use a couple of different ones for "serious" vs "fun") for the application. There was an article, which I couldn't find again, that also had metrics on how
  6. Some even say we don't need passwords... (https://medium.com/@SuperPaintman/your-users-dont-need-a-password-9e3fa492f69)
  7. Use "login" for log in and "Register" for signup (https://uxplanet.org/designing-ux-login-form-and-process-8b17167ed5b9), which has other good tips as well.
  8. Add a "forgot password" link to the login form
  9. Add a "keep me signed in" checkbox to the login form
  10. Add some kind of 2-factor authentication using apps like Authenticator from Google, Microsoft, Steam App, Facebook App, or any of the solutions mentioned in the linked articles
  11. Do a live lookup for "username exists" and suggest alternatives (mostly for popular solutions)

Most of these are opinions, but some should be ready-out-of-the-box for a framework.

In general, people shouldn't have to give up too much information to log in. Ask for the information when needed. For example, First name, Last name, when is it needed? Not when signing up, especially since username is the unique identifier for the user. This, of course, is different from application to application. So how about adding some kind of hierarchy to information. Say that we don't send a registration e-mail upon registration. Then after the user has returned to the site at least 24 hours later, then we send a welcome back e-mail, please add your real name to your profile.

The goal is to ease people into using the application/site and making sure they return again and again. For anyone making a shopping application/site, this article has additional tips on how to make the experience smoother (https://blog.kissmetrics.com/first-step-of-checkout/)

Too much for one issue?

Hey, nice project!

What about narrow the gate enlarge the bait!?
In lieu of express use micro, instead of mongo use arango.
At least would be a superior solution IMHO

Vueniverse v2

I'd like to create Vueniverse version 2. Some thoughts

  • GraphQL and Apollo
  • Remove Redis caching / blacklisting as it provides little value (and defeats the purpose of stateless JWT)
  • Deploy to Now 2.0 using @nuxtjs/now-builder
  • use the new-er @vue/cli
  • Typescript?

It'll look a lot like what Atlify is right now.

npm run dev

node -v
v8.0.0
npm -v
5.3.0
DONE Compiled successfully in 403ms
(node:14125) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): TypeError: __WEBPACK_IMPORTED_MODULE_6_nuxt___default.a is not a constructor

Admin interface

Admin Interface

Time to create a legit admin interface for this project. It should include

  • Admin's should sign-in at the same place everyone else does.

  • /admin: An admin home page, with quick insights related to page views and statistical graphs.

  • /admin/users: A queryable user table using vuetify data tables, #6 and some server side magic. Admins should have the ability to revoke tokens from users, delete users, or revoke their current passwords.

  • Protecting routes on the API should be as simple as throwing an option in the authenticate middleware. ex: router.get('/admin', authenticate({ role: ['admin', 'owner'] }), index.get)

  • "401 Unauthorized" errors should follow suit with express-server-error.js.

Problem in Production

Hi,

Firstly, thank you very much for your work.
Like I said in the title, after running yarn build. I ran the following command nodemon /dist/server/main.js
Then, open the application on the browser, it's just loading with nothing rendered. Only these routes to the api works. Deploying to Now run into the same issue.

Please help me out. Thank you very much.

Missing License

Great repository!

But you should definitely add a license to this repo (MIT or similar) and submit it to awesome-vue.

Argon2 seems to be a show stopper

I was looking forward to testing this awesome library due to its combination of MongoDB, Express, Nuxt and even SSR. But I'm not able to get i up and running on my setup, which is:

  • Windows 10
  • VScode 64-bit, which also runs my terminal
  • Node 8.1.2
  • MongoDB 3.4.7 - both with and without mongod running

Some suspects:

  • argon2 was missing (did a npm install --save argon2 but install didn't work)
  • missing python

Does Argon2 simply not run on Windows:
ranisalt/node-argon2#34

I'll leave the full log to you - and hope the best:

Windows PowerShell
Copyright (C) 2016 Microsoft Corporation. All rights reserved.

PS F:\frontend\vue\fullstack> vue init rlindskog/vueniverse vueniverse

? Project name vueniverse
? Project description Første test med init
? Author Jan Larsen
? Choose a session strategy (for blacklisting JWTs) in-memory

   vue-cli · Generated "vueniverse".

   To get started:

     cd vueniverse
     npm install
     npm run start-db
     npm run dev

   Documentation can be found at https://www.github.com/rlindskog/vueniverse

PS F:\frontend\vue\fullstack> cd vueniverse
PS F:\frontend\vue\fullstack\vueniverse> npm install
npm WARN deprecated [email protected]: Use uuid module instead

> [email protected] install F:\frontend\vue\fullstack\vueniverse\node_modules\argon2
> node-gyp rebuild


F:\frontend\vue\fullstack\vueniverse\node_modules\argon2>if not defined npm_config_node_gyp (node "C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\n
ode-gyp.js" rebuild )  else (node "" rebuild )
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
gyp ERR! stack     at PythonFinder.failNoPython (C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:483:19)
gyp ERR! stack     at PythonFinder.<anonymous> (C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:508:16)
gyp ERR! stack     at C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\graceful-fs\polyfills.js:284:29
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:152:21)
gyp ERR! System Windows_NT 10.0.15063
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\Jan\\AppData\\Roaming\\npm\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd F:\frontend\vue\fullstack\vueniverse\node_modules\argon2
gyp ERR! node -v v8.1.2
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN [email protected] requires a peer of ajv@>=5.0.0 but none was installed.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Jan\AppData\Roaming\npm-cache\_logs\2017-08-23T18_11_00_575Z-debug.log
PS F:\frontend\vue\fullstack\vueniverse> node -v
v8.1.2
PS F:\frontend\vue\fullstack\vueniverse> npm install --save argon2

> [email protected] install F:\frontend\vue\fullstack\vueniverse\node_modules\argon2
> node-gyp rebuild


F:\frontend\vue\fullstack\vueniverse\node_modules\argon2>if not defined npm_config_node_gyp (node "C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\n
ode-gyp.js" rebuild )  else (node "" rebuild )
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
gyp ERR! stack     at PythonFinder.failNoPython (C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:483:19)
gyp ERR! stack     at PythonFinder.<anonymous> (C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:508:16)
gyp ERR! stack     at C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\graceful-fs\polyfills.js:284:29
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:152:21)
gyp ERR! System Windows_NT 10.0.15063
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\Jan\\AppData\\Roaming\\npm\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd F:\frontend\vue\fullstack\vueniverse\node_modules\argon2
gyp ERR! node -v v8.1.2
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN [email protected] requires a peer of ajv@>=5.0.0 but none was installed.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Jan\AppData\Roaming\npm-cache\_logs\2017-08-23T18_18_36_164Z-debug.log
PS F:\frontend\vue\fullstack\vueniverse> npm install

> [email protected] install F:\frontend\vue\fullstack\vueniverse\node_modules\argon2
> node-gyp rebuild


F:\frontend\vue\fullstack\vueniverse\node_modules\argon2>if not defined npm_config_node_gyp (node "C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\n
ode-gyp.js" rebuild )  else (node "" rebuild )
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
gyp ERR! stack     at PythonFinder.failNoPython (C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:483:19)
gyp ERR! stack     at PythonFinder.<anonymous> (C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:508:16)
gyp ERR! stack     at C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\graceful-fs\polyfills.js:284:29
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:152:21)
gyp ERR! System Windows_NT 10.0.15063
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\Jan\\AppData\\Roaming\\npm\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd F:\frontend\vue\fullstack\vueniverse\node_modules\argon2
gyp ERR! node -v v8.1.2
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN [email protected] requires a peer of ajv@>=5.0.0 but none was installed.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Jan\AppData\Roaming\npm-cache\_logs\2017-08-23T18_18_59_462Z-debug.log
PS F:\frontend\vue\fullstack\vueniverse> npm run start-db

> [email protected] start-db F:\frontend\vue\fullstack\vueniverse
> mongod --fork --dbpath ./db/data --logpath ./db/logs/mongodb.log

Error parsing command line: unrecognised option '--fork'
try 'mongod --help' for more information
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! [email protected] start-db: `mongod --fork --dbpath ./db/data --logpath ./db/logs/mongodb.log`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the [email protected] start-db script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Jan\AppData\Roaming\npm-cache\_logs\2017-08-23T18_20_00_201Z-debug.log
PS F:\frontend\vue\fullstack\vueniverse> npm run dev

> [email protected] dev F:\frontend\vue\fullstack\vueniverse
> backpack dev



 ERROR  Failed to compile with 2 errors                                                                                                                                                         20:20:51

This dependency was not found:

* argon2 in ./src/server/api/users/controllers.js, ./src/server/api/users/models.js

To install it, you can run: npm install --save argon2
module.js:487
    throw err;
    ^

Error: Cannot find module 'F:\frontend\vue\fullstack\vueniverse\dist\server\main.js'
    at Function.Module._resolveFilename (module.js:485:15)
    at Function.Module._load (module.js:437:25)
    at Function.Module.runMain (module.js:605:10)
    at startup (bootstrap_node.js:158:16)
    at bootstrap_node.js:575:3
Terminate batch job (Y/N)? y
PS F:\frontend\vue\fullstack\vueniverse> npm install --save argon2

> [email protected] install F:\frontend\vue\fullstack\vueniverse\node_modules\argon2
> node-gyp rebuild


F:\frontend\vue\fullstack\vueniverse\node_modules\argon2>if not defined npm_config_node_gyp (node "C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\n
ode-gyp.js" rebuild )  else (node "" rebuild )
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
gyp ERR! stack     at PythonFinder.failNoPython (C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:483:19)
gyp ERR! stack     at PythonFinder.<anonymous> (C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:508:16)
gyp ERR! stack     at C:\Users\Jan\AppData\Roaming\npm\node_modules\npm\node_modules\graceful-fs\polyfills.js:284:29
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:152:21)
gyp ERR! System Windows_NT 10.0.15063
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\Jan\\AppData\\Roaming\\npm\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd F:\frontend\vue\fullstack\vueniverse\node_modules\argon2
gyp ERR! node -v v8.1.2
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN [email protected] requires a peer of ajv@>=5.0.0 but none was installed.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Jan\AppData\Roaming\npm-cache\_logs\2017-08-23T18_24_00_512Z-debug.log
PS F:\frontend\vue\fullstack\vueniverse>

Deploy with NOW

Hi ! I'm using your template and I want to deploy my project with Now (or anything as Netlify or Heroku). But when I run now in my application, I have an error.

 Error! An unexpected error occurred!
  Error: File size limit exceeded (1 MB) (400)
    at responseError (C:\snapshot\repo\dist\now.js:2253:15)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:188:7) Error: File size limit exceeded (1 MB) (400)
    at responseError (C:\snapshot\repo\dist\now.js:2253:15)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:188:7)

Production usage

Hi, first of all this is a great project and im using for my mainly project, really thankful for that.

So i'm trying to build the project and i stuck in some things, first when you start the server in production mode ( after build ) this get a error saying that there is no DB_URL, so i just put "mongodb://127.0.0.1/test" in .prod.env and fixed, after that i get a error because its not that simple to use port 80 to server, so i changed to 3000 and its okay, but now, in production mode the login function its not working, when i put the credentials in console says " Sign In pending... " forever, but sign up works correctly, can you help me with that ?

Thank you for all.

Create admin not login

I can not signin in to the generated password for the admin.
Is there some dependencies not installed additionally? As an example of argon2?
can be setting mongodb local?

Stopped by snackbar

After having installed the updated code after this fix I managed to get something shown on localhost:3000 on my Windows 10 laptop.

But no rocket or anything similar...

Instead I got this error message about snackbar: src/client/layouts/default.vue:150: VueComponent.get:

 },
  computed: {
    snackbar: {
      get () {
        return this.$store.state.toast.snackbar
      },
      set (value) {
        this.$store.commit('toast/UPDATE_SNACKBAR', value)
      }
    }
  }

along with this error message: src/client/layouts/default.vue:163: Proxy.render:

Missing stack frames

Haven't got a clue, what might be the problem here. Could it be the fact, that

  1. I'm activating mongod manually in a separate terminal (npm run start-db won't work in my setup)?
  2. Nuxt is getting updated frequently due to the present intense v. 1.0 development?
  3. Would it be better to hold the horses, until Nuxt 1.0 hits the street?

My log for further reference:

PS F:\frontend\vue\fullstack> vue init rlindskog/vueniverse vueniverse

? Target directory exists. Continue? Yes
? Project name testandenrunde
? Project description A Vueniverse project
? Author Jan Larsen
? Choose a session strategy (for blacklisting JWTs) in-memory

   vue-cli · Generated "vueniverse".

   To get started:

     cd vueniverse
     npm install
     npm run start-db
     npm run dev

   Documentation can be found at https://www.github.com/rlindskog/vueniverse

PS F:\frontend\vue\fullstack> cd vueniverse
PS F:\frontend\vue\fullstack\vueniverse> npm install
npm WARN deprecated [email protected]: Use uuid module instead

> [email protected] postinstall F:\frontend\vue\fullstack\vueniverse\node_modules\uglifyjs-webpack-plugin
> node lib/post_install.js


> [email protected] postinstall F:\frontend\vue\fullstack\vueniverse\node_modules\nuxt
> opencollective postinstall || exit 0


     *** Thank you for using nuxt! ***

Please consider donating to our open collective
     to help us maintain this package.

  https://opencollective.com/nuxtjs/donate

                    ***

npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN [email protected] requires a peer of ajv@>=5.0.0 but none was installed.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (
current: {"os":"win32","arch":"x64"})

added 1429 packages in 142.039s
PS F:\frontend\vue\fullstack\vueniverse> npm run start-db

> [email protected] start-db F:\frontend\vue\fullstack\vueniverse
> mongod --fork --dbpath ./db/data --logpath ./db/logs/mongodb.log

Error parsing command line: unrecognised option '--fork'
try 'mongod --help' for more information
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! [email protected] start-db: `mongod --fork --dbpath ./db/data --logpath ./db/logs/mongodb.log`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the [email protected] start-db script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Jan\AppData\Roaming\npm-cache\_logs\2017-08-31T12_26_13_503Z-debug.log
PS F:\frontend\vue\fullstack\vueniverse> npm run start-db

> [email protected] start-db F:\frontend\vue\fullstack\vueniverse
> mongod --fork --dbpath ./db/data --logpath ./db/logs/mongodb.log

Error parsing command line: unrecognised option '--fork'
try 'mongod --help' for more information
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! [email protected] start-db: `mongod --fork --dbpath ./db/data --logpath ./db/logs/mongodb.log`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the [email protected] start-db script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Jan\AppData\Roaming\npm-cache\_logs\2017-08-31T12_26_38_682Z-debug.log
PS F:\frontend\vue\fullstack\vueniverse> npm run dev

> [email protected] dev F:\frontend\vue\fullstack\vueniverse
> backpack dev



 DONE  Compiled successfully in 2444ms                                                                              14:27:04

Server listening on http://127.0.0.1:3000
Build completed in 23.586s



 DONE  Compiled successfully in 23591ms                                                                             14:27:36

[Vue warn]: Error in render function: "TypeError: Cannot read property 'snackbar' of undefined"

found in

---> <Default> at src\client\layouts\default.vue
       <Root>
[Vue warn]: Error in render function: "TypeError: Cannot read property 'snackbar' of undefined"

found in

---> <Default> at src\client\layouts\default.vue
       <Root>

npm run dev - error in ./src/server/index.js

ERROR Failed to compile with 1 errors 4:38:12 PM

error in ./src/server/index.js

Module build failed: Error: Couldn't find preset "env" relative to directory "/home/alex"
at /home/alex/vueniverse/node_modules/babel-core/lib/transformation/file/options/option-manager.js:293:19
at Array.map (native)
at OptionManager.resolvePresets (/home/alex/vueniverse/node_modules/babel-core/lib/transformation/file/options/option-manager.js:275:20)
at OptionManager.mergePresets (/home/alex/vueniverse/node_modules/babel-core/lib/transformation/file/options/option-manager.js:264:10)
at OptionManager.mergeOptions (/home/alex/vueniverse/node_modules/babel-core/lib/transformation/file/options/option-manager.js:249:14)
at OptionManager.init (/home/alex/vueniverse/node_modules/babel-core/lib/transformation/file/options/option-manager.js:368:12)
at File.initOptions (/home/alex/vueniverse/node_modules/babel-core/lib/transformation/file/index.js:212:65)
at new File (/home/alex/vueniverse/node_modules/babel-core/lib/transformation/file/index.js:135:24)
at Pipeline.transform (/home/alex/vueniverse/node_modules/babel-core/lib/transformation/pipeline.js:46:16)
at transpile (/home/alex/vueniverse/node_modules/babel-loader/lib/index.js:50:20)

module.js:472
throw err;
^

Error: Cannot find module '/home/alex/vueniverse/dist/server/main.js'
at Function.Module._resolveFilename (module.js:470:15)
at Function.Module._load (module.js:418:25)
at Module.runMain (module.js:605:10)
at run (bootstrap_node.js:427:7)
at startup (bootstrap_node.js:151:9)
at bootstrap_node.js:542:3

Implementation question

Hi, first off, great project. There are not enough Vue + Express starters, and its really nice to have Auth built in as well. I was taking a look at the code and ran into an impass when trying to figure out how you integrate the store into the vue app. I see that you include vuex but there is no where in the code where it is actually included. The same goes for component usage of the store, I cannot find where you instantiate the Vue instance and include the store. Am I missing something? This all seems to be wired up and working, I just have no idea how you load the store into the vue instance. Im always interested in getting other perspectives on best practices for VueJS development, so any feedback would be greatly appreciated. Cheers

Live demo error

Hello, there is an error when trying to access the live demo.

Error: Cannot find module 'source-map-support/register'
    at Function.Module._resolveFilename (module.js:536:15)
    at Function.Module._load (module.js:466:25)
    at Module.require (module.js:579:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (/home/nowuser/src/dist/server/main.js:1:63)
    at Module._compile (module.js:635:30)
    at Object.Module._extensions..js (module.js:646:10)
    at Module.load (module.js:554:32)
    at tryModuleLoad (module.js:497:12)
    at Function.Module._load (module.js:489:3)

JWT Token in Cookie

Could you please show me where you are setting token as cookie. I can't see it in Sigin.post route handler.

Nuxt Generate Support

Great project! do you plan to support nuxt generate in order to create an static version of the client side?

social authentication integration

The email+pwd only auth is pretty limiting for current scenarios. It'd have been great if an oauth integration for at least google, fb and twitter were baked in. Any chance of this coming anytime soon? I'm struggling a bit on that part. Any help is appreciated

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.