Unable to create an Express app in WebStorm - node.js

I tried to create the node application in this directory: C:\Users\VINOTH RAVI\WebstormProjects but I'm not able to create the nodejs app.
I enclosed the error.
Can anyone solve this issue?

I think this problem has already been flagged on IntelliJ's support site.
Here is a link to the answer:
https://intellij-support.jetbrains.com/hc/en-us/community/posts/115000137190-Create-express-4-15-project-fails-?page=1#community_comment_115000174210
npm install -g express-generator
express <project_name>
cd <project_name>, npm install
in webstorm, File | open, choose <project_name> folder

Related

error after installing bootstrap in an existing vue project

I have an existing Vue project and I want to add Boostrap into it. I ran this command (following this tutorial)
npm install bootstrap jquery popper.js
And then, I got an error in the Vue project.
./node_modules/core-js/modules/es.array.iterator.js module build failed: error: enoent: no such file or directory
I have tried deleting node_modules folder and package-lock.json then running npm install, but it didn't work. I also have tried to clear cache but it didn't work. I also have tried running npm install from my cmd but it didn't work as well.
Any other suggestions? Thanks!
Which version of vue are you using (2, 3)? Have you considered using Bootstrap Vue?
I just did the same method a few hours later and it succeeded. I think probably it also depends on your Internet connection.

How to get Started with Ember on windows using npm?

C:\Users\andri>cd ember-cli
Das System kann den angegebenen Pfad nicht finden.
C:\Users\andri>npm install -g bower
npm WARN deprecated bower#1.8.2: ...psst! Your project can stop working at any moment because its dependencies can change. Prevent this by migrating to Yarn: https://bower.io/blog/2017/how-to-migrate-away-from-bower/
C:\Users\andri\AppData\Roaming\npm\bower -> C:\Users\andri\AppData\Roaming\npm\node_modules\bower\bin\bower
+ bower#1.8.2
added 1 package in 23.177s
C:\Users\andri>ember new testapp-app
installing app
create .editorconfig
create .ember-cli
create .eslintrc.js
create .travis.yml
create .watchmanconfig
create README.md
create app\app.js
create app\components\.gitkeep
create app\controllers\.gitkeep
create app\helpers\.gitkeep
create app\index.html
create app\models\.gitkeep
create app\resolver.js
create app\router.js
create app\routes\.gitkeep
create app\styles\app.css
create app\templates\application.hbs
npm: Installed dependencies
Successfully initialized git.s
C:\Users\andri>ember server
node_modules appears empty, you may need to run `npm install`
C:\Users\andri>bower install
bower ENOENT No bower.json present
C:\Users\andri>ember server
node_modules appears empty, you may need to run `npm install`
I am trying to install ember and keep getting errors. Does anybody understand what I am doing wrong? I am watching a youtube tutorial and I follow the steps that are on the video, still it doesnt work, in fact I get totally different results :/ I have also installed git.. Could somebody explain to me what is happening here? I am very new to all these and therefore I cannot spot the mistakes. Thank you in advance
For Windows Users:::
Install Node js for windows and then install npm package for it and if you have done that.
You can install ember from npm.
Install Ember using npm:
npm install -g ember-cli#3.0
To verify that your installation was successful, run:
ember -v
If a version number is shown, you're ready to go.
see the link below for more details...
https://guides.emberjs.com/v3.0.0/getting-started/
looking your prompt, to start a ember server, just go to your ember app folder (cd\testapp-app) and use ember serve or ember s
Your last error there is telling you what's missing.
node_modules appears empty, you may need to run npm install
Running npm install in the project folder and then running ember server should get you up and running. The default URL is http://localhost:4200 when ember-cli has spun up the server.

Why is Express not working at all?

I have been following the steps on this I got as far as
npm install -g express-generator
but then nothing happens when I try to create an express project. I go to the directory I want it to be in and type
express nodetest1
and nothing happens. It just returns to the next line. It seems like everything installed correctly.
Edit: My link was to the wrong tutorial. This is the right one now.
Did you try starting the server? The express-generator only generates the project.
Change to the directory of the created project and do npm install followed by npm start to start the server.
Turns out it was caused by nodejs, not Express. When I installed the latest version usinv nvm instead of apt-get, express started working.
What you want is
npm install -g express
There is a generator included in the main package.
So then you can use
express nodetest1
and everything works!

express not installed on my machine

I downloaded node.js onto my linux fedora core 18 machine.
After that using npm -g install express installed express. The problem is I am unable to find the express file to be supplied to Nodeclipse in the preference.
Hence, my application using express is not able to compile saying express not found.
Am I missing anything here?
try installing it with this command and see if it works:
npm install -g express
then go to cd myapp
npm link express
this could do the trick..
Nodeclipse is using express executable only for wizard. Everything else works as for node.js from command line (try node myapp.js)
As advised by #isaacs in Express module not found when installed with NPM, do npm install express for local project folder.

NPM basics with nave and Node.js

I recently installed node.js and was told that express was the way to go for routing and getting set up with web application development.
I installed the latest version of node which apparently is incompatible with the latest express.
I looked up and found nave... Like RVM, nave allows you to switch versions of node. So I ran nave.sh install 0.4.11... That worked successfully and I was able to run.
npm install express -g
This I thought, should install express globally. So I run:
express testapp
which creates
create : testapp
create : testapp/package.json
create : testapp/app.js
create : testapp/public/stylesheets
create : testapp/public/stylesheets/style.css
create : testapp/public/images
create : testapp/public/javascripts
create : testapp/views
create : testapp/views/layout.jade
create : testapp/views/index.jade
Then I
cd testapp/
node app.js
I get
Error: Cannot find module 'express'
Is this usual behavior?
Since express is in packages.json, if I run npm install -d, it will create a node_modules directory in my application and not just symlink to the node_modules in my node path.
In a word, yes, this is the usual behavior.
When you install packages using NPM with -g option, it installs it globally, which does nice things like putting executeables on your path (i.e. the express script you used)
However, it does NOT put those packages anywhere that node can find them.
To install it so node can find the package, you must also do
cd "your express app"
npm install express
which installs locally (to the node_modules folder in the root of your application dir).
This is primarily to avoid any dependencies conflicts, and though it may seem silly, it is in fact really useful.
If you have some real reason to want to use your global install (say for example you have many applications that you want to make sure always share the same version) you can use the npm link command.
For a good rundown of NPM and global vs local see this blog post.
If you are on Windows, add location to your path.
export NODE_PATH="C:\Users\IMarek\AppData\Roaming\npm\node_modules"
Change: IMarek to your user name.

Resources