Running node.js and dependencies

@endurance21 i have installed dependencies from ubuntu only. But i don’t know how to run the code on ubuntu.
OUTPUT from ubuntu:

@Prabhleen
No worries
First things you have to go to the directory of project and then do :blush:
Npm start

You are doing at home directory now, :sweat_smile:

@endurance21
Now i tried in the project directory, it give same error.
It doesn’t show which version of npm

i tried running the command for version in root, it works:
image

In the user terminal it shows that npm is downloaded in node_modules:

So, first i tried running in VS code, there the error (#! /usr/bin/env node ^SyntaxError: Invalid or unexpected token) can’t be resolved. This error comes from build-less and build-client-js files for styling, everything else is working. I surfed for this a lot but with no success.

Then i tried running in ubuntu, where i downloaded the project and node.js, (npm should have been installed with the nodejs package only, but didn’t and gives the error as above.)
Hence, i was not able to continue with this also.

And now i am going to install Docker using linux and i hope it goes well. :slightly_smiling_face:

@Prabhleen
Have you installed npm using
Sudo apt install npm - g
Have you used global (-g) flag while installing…

That’s the problem. I think.
Please install npm using NVM,
Node version manager.

Go through this, there is a section on page, “How To Install Using NVM”
Also change the version of your Ubuntu if it is 18.04, there is a blue button at starting of page to do so.

2 Likes

THANKS A LOT! IT REALLY SOLVED THE ISSUE.
so, now as my dependencies were running earlier, do i have to install something else like babel?

@Prabhleen
Good to hear that, finally! :sweat_smile:

No need to install babel.
All you need to do is go to the directory,
And type command ‘npm install’, it will automatically download all essential dependencies…

1 Like

Hi everyone! apologies for delay in reply and no updates. :confused:
As my exams start tomorrow (2.3.19) and will continue till Saturday (7.3.19), i will not be able to participate or contribute to BookBrainz.
i will shortly resume from Sunday (8.3.19)
Thank You.
@mr_monkey

1 Like