$ sudo npm install -g express the installation goes fine. But when I try to create a project with express as $ express myProject I get an error saying

: The program 'express' is currently not installed. You can install it by typing: sudo apt-get install node-express

The new version of Express (4.0) does not itself have a bin folder. You have to install express-generator to get the setup functionality.

You are not doing anything wrong. Express has just changed the way it works. Have a look at this answer.

With Express 4, the application generator was removed and is now available as 'express-generator.' So you need to npm install -g express-generator instead.

express@4.0.*的更多相关文章

  1. Node Express 4.0 安装

    前言 今天想要用nodejs 写个后台服务,很久之前看过node express 框架,可真当向下手安装的时候,发现好多命令都不记得了.写完后台服务,没事了,总结了下安装过程,记录一下,以便以后查阅方 ...

  2. NodeJS - Express 4.0下使用app.dynamicHelpers错误

    在NodeJS - Express 4.0下使用app.dynamicHelpers发生错误: app.dynamicHelpers({ ^ TypeError: Object function (r ...

  3. NodeJS -Express 4.0 用include取代partial

    在Express 4.0 下按如下方法设置: (1)运行cmd 输入:npm install express-partials -g (2)下载成功后.在app.js 中引用此插件   var par ...

  4. NodeJS - Express 3.0下ejs模板使用 partial展现 片段视图

    如果你也在看Node.js开发指南,如果你也在一步一步实现 microBlog 项目!也许你会遇到本文提到的问题,如果你用的是Express 3.0 本书实例背景是 Express 2.0 而如今升级 ...

  5. express 3.0.x 中默认不支持layout.ejs的解决方法

    1.第一种方法用include 用<% include 模板名(可不加.ejs) %>的写法,具体如下 <% include header %> //套用布局拆成两部分 hea ...

  6. Express 3.0新手指南入门教程

    在确认已经安装了node之后(下载), 在你的机器上创建一个目录,让我们来开始你的第一个应用程序吧 $ mkdir hello-world 在这个目录中你首先得定义一下你的应用程序“包”文件,它和其它 ...

  7. NodeJS - Express 4.0错误:Cannot read property 'Store' of undefined

    按着<NodeJS开发指南>里的第五章建立microblog的例子操作,使用node.js 的express框架配置将session存储到mongodb时出错:TypeError: Can ...

  8. express 4.0 connect-mongo 运行时报错的解决方法

    如果使用的是express 4.0,且入口文件app.js的模板引入和中间件配置如下 如果你的package.json文件中有以下版本信息 报出的错误如下所示    或者  那么只需修改app.js中 ...

  9. Node + Express + vue2.0 + Webpack项目实践

    技术 Express.Vue.Vue-Router.Vue-Resource.Webpack Vue vue 的组件化思想和 React 很像,一个 vue 组件将 html.css 和 js 都写在 ...

随机推荐

  1. When to use static method in a java class

    First , please understand its feature : * no need to instantiate a instance, i.e. simply you can jus ...

  2. Spark编程指南V1.4.0(翻译)

    Spark编程指南V1.4.0 ·        简单介绍 ·        接入Spark ·        Spark初始化 ·        使用Shell ·        在集群上部署代码 ...

  3. mysql select语句执行顺序

        SELECT语句定义       一个完成的SELECT语句包含可选的几个子句. SELECT语句的定义如下: <SELECT clause> [<FROM clause&g ...

  4. iTunes Connect App Bundles

    App Bundles捆绑销售提交流程: 1. 在iTunes Connect左上「+」选「Create Bundle」到「New App Bundle」挑选已上线应用(最多可捆绑10个应用) 2. ...

  5. springBoot 2.X-自定义拦截器

    package com.cx.springboot.myInter; import javax.servlet.http.HttpServletRequest; import javax.servle ...

  6. nodejs 服务器 崩溃 2种解决办法

    用node启动server后,发现服务器不稳定,经常crash.我是用ssh远程登录的,ssh远程通道中断,或者Ctrl+C,都会使nodejs server崩溃掉. 一,node server 崩溃 ...

  7. appium+python自动化52-多点触控MultiAction

    前言 MultiAction是针对多点触控操作的,是TouchAction的一个补充模块 TouchAction用法参考前面的一篇:appium+python自动化33-TouchAction 多点触 ...

  8. Eclipse中在android项目中出现新建一个Activity后,出现整个project的报错以及包导入以后无法执行等等情况分析。

    今天用Eclipse去写android项目,然后后面须要建一个Blank  Activity后,非常正常的建立的.然后那个Activity是基于ActionBarAtivity,要导入v7,结果由于这 ...

  9. poj2142 The Balance 扩展欧几里德的应用 稍微还是有点难度的

    题目意思一开始没理解,原来是 给你重为a,b,的砝码 求测出 重量为d的砝码,a,b砝码可以无限量使用 开始时我列出来三个方程 : a*x+b*y=d; a*x-b*y=d; b*y-ax=d; 傻眼 ...

  10. [Python爬虫] 之五:Selenium 处理滚动条

     selenium并不是万能的,有时候页面上操作无法实现的,这时候就需要借助JS来完成了. 当页面上的元素超过一屏后,想操作屏幕下方的元素,是不能直接定位到,会报元素不可见的.这时候需要借助滚动条来拖 ...