1. 程式人生 > >angular4啟動專案時出現的錯

angular4啟動專案時出現的錯

D:\web\angular>npm serve


Usage: npm <command>


where <command> is one of:
    access, adduser, bin, bugs, c, cache, completion, config,
    ddp, dedupe, deprecate, dist-tag, docs, doctor, edit,
    explore, get, help, help-search, i, init, install,
    install-test, it, link, list, ln, login, logout, ls,
    outdated, owner, pack, ping, prefix, profile, prune,
    publish, rb, rebuild, repo, restart, root, run, run-script,
    s, se, search, set, shrinkwrap, star, stars, start, stop, t,
    team, test, token, tst, un, uninstall, unpublish, unstar,
    up, update, v, version, view, whoami


npm <command> -h     quick help on <command>
npm -l           display full usage info
npm help <term>  search for help on <term>
npm help npm     involved overview


Specify configs in the ini-formatted file:
    C:\Users\zqq\.npmrc
or on the command line via: npm <command> --key value
Config info can be viewed via: npm help config


[email protected]
D:\資料\web前端資料\nodejs\node_modules\npm


D:\web\angular>ng serve
module.js:538
    throw err;
    ^


Error: Cannot find module '@angular-devkit/core'
    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> (D:\web\angular\node_modules\@angular-devkit\schematics\src\tree\virtual.js:10:16)
    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)


D:\web\angular>npm update -g @angular/cli
[..................] \ loadDep:webpack-sources: sill resolveWithNewModule
[email protected]
checking inst[..................] \ loadDep:webpack-sources: sill resolveWi[..................] | fetchMetadata: sill resolveWithNewModule [email protected] checking installable status[..................] | fetchMetadata: sill resoC:\Users\zqq\AppData\Roaming\npm\ng -> C:\Users\zqq\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
npm WARN optional SKIPPING OPTIONAL DEPENDENCY:
[email protected]
(node_modules\@angular\cli\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})


+ @angular/[email protected]
added 340 packages, removed 148 packages, updated 121 packages and moved 2 packages in 198.821s


D:\web\angular>ng server
Your global Angular CLI version (1.7.2) is greater than your local
version (1.6.0). The local Angular CLI version is used.


To disable this warning use "ng set --global warnings.versionMismatch=false".
module.js:538
    throw err;
    ^


Error: Cannot find module '@angular-devkit/core'
    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> (D:\web\angular\node_modules\@angular-devkit\schematics\src\tree\virtual.js:10:16)
    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)


D:\web\angular>npm install @angular-devkit/core --save-dev
npm WARN @angular-devkit/[email protected] requires a peer of @angular-devkit/[email protected] but none is installed. You must install peer dependencies yourself.
npm WARN @schematics/[email protected] requires a peer of @angular-devkit/[email protected] but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] requires a peer of [email protected]^6.0.0 but none is installed. You must install peer dependencies yourself.
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"})


+ @angular-devkit/[email protected]
added 127 packages in 15.629s


D:\web\angular>npm update -g @angular/cli


D:\web\angular>ng server
Your global Angular CLI version (1.7.2) is greater than your local
version (1.6.0). The local Angular CLI version is used.


To disable this warning use "ng set --global warnings.versionMismatch=false".
** NG Live Development Server is listening on localhost:4200, open your browser on http://localhost:4200/ **
Date: 2018-03-01T07:19:46.296Z
Hash: 360e766258fbfb58aa95
Time: 8027ms
chunk {inline} inline.bundle.js (inline) 5.79 kB [entry] [rendered]
chunk {main} main.bundle.js (main) 20.2 kB [initial] [rendered]
chunk {polyfills} polyfills.bundle.js (polyfills) 549 kB [initial] [rendered]
chunk {styles} styles.bundle.js (styles) 33.6 kB [initial] [rendered]
chunk {vendor} vendor.bundle.js (vendor) 7.41 MB [initial] [rendered]


webpack: Compiled successfully.

相關推薦

angular4啟動專案出現

D:\web\angular>npm serveUsage: npm <command>where <command> is one of:    access, adduser, bin, bugs, c, cache, completion,

tomcat 啟動專案出現 ZipException: error in opening zip file

錯誤情況 專案用 maven 打好 war 包後放到 tomcat 下,啟動 tomcat,出現以下錯誤 3-Nov-2017 12:21:44.346 嚴重 [localhost-startStop-1] org.apache.catalina.core.ContainerBase

啟動專案出現java.io.EOFException異常。

啟動專案時報以下異常 嚴重: Exception loading sessions from persistent storage java.io.EOFException 遇到上述異常,刪除Tomcat裡面的work\Catalina\localhost下的專案檔案

1、webpack搭建專案出現的報“Module build failed (from ./node_modules/css-loader/dist/cjs.js) CssSyntaxError”

控制檯出現的錯誤如下:                    webpack.config.js中的配置如下: module.exports={ entry:'./src/main.js

Run as啟動專案總報Failed to start component [StandardEngine[Tomcat].StandardHost[localhost].StandardCont

[INFO] Scanning for projects... [INFO]                                                                         [INFO] ------------------------------------

VMware啟動Centos出現錯誤Cannot open the disk 'xxxxxxx.vmdk' or one of the snapshot disks it depends on. .

每次 pan 鎖定 mic 數據 als log xxxxxx end   今天拔裝虛擬機的硬盤的時候,沒有關掉虛擬機,導致虛擬打開的時候出現:Cannot open the disk ‘xxxxxxx.vmdk‘ or one of the snapshot disk

啟動tomcat出現tomcat setting should be set in tomcat preference page

ont 分享 gravity tails AI BE step detail art 轉自:https://blog.csdn.net/withyou_wy/article/details/53081800 出現此狀況證明你的tomcat在配置的時候沒有配置成功,通過以

打包maven專案出現Failed to execute goal org.apache.maven.plugins:maven-war-plugin:2.2:war (default-war)

當一個maven專案是web工程的時候,要注意新增web.xml檔案,一般預設是建立在main目錄下的webapp/WEB-INF/web.xml,當然,如果你選擇了maven 動態模板,會自動幫你建好這個目錄,如果沒有的話,你就要自己建立了。 如果沒有的話,會報錯:[ERROR] Failed

Maven 打包專案出現的錯誤

打包時,沒有install 依賴專案 使用maven管理的spring boot 專案,專案A 依賴專案B,在打包專案A的時候,出現下面的錯誤 報錯: Failed to execute goal on project hong-bao: Could not resolve

myeclipse 2013在Tomcat釋出專案出現404問題的一些原因及解決方法

Myeclipse在開發的過程中,有時要重新修改專案名稱,但是部署在Tomcat上的webapps下面的專案名稱卻一直是上一個的專案名稱。可能的原因及解決方法: 1、mymatadata 檔案丟失 (找一個原來的新增上就ok) 2、mymatadata 檔案確實沒有在mymatadata

idea啟動專案,debug模式特別慢

1,問題: idea非debug模式,能夠正式的速度啟動專案, 而debug模式啟動時,啟動速度特別慢,甚至就像卡著一樣,幾乎啟動不了專案。 2,原因: 專案中有的地方打了斷點,所以啟動時受到影響 3,解決方法:如圖所示,在idea底部操作攔中選擇“Debug",然後點選如圖

Debug模式啟動專案啟動不起來

如題,今天在使用Debug啟動專案的時候,發現啟動不起來,現象是啟動的非常慢,10分鐘之後還是沒起來 於是開始排查問題,啟動專案的時候用的是JRebel熱部署外掛,所以首先想是否是外掛問題。   外掛有一個提示:Loaded classes are up to date,Nothing t

tomcat部署專案Tomcat version 7.0 only supports J2EE 1.2, 1.3, 1.4, and Java EE 5 and 6 Web modules

Tomcat version 7.0 only supports J2EE 1.2, 1.3, 1.4, and Java EE 5 and 6 Web modules   解決方法: 找到檔案 .settings->org.eclipse.wst.common.

關於tomcat啟動專案一直卡住無反應的場景之一

       最近碰到一次專案啟動半天沒反應,也不報錯,專案在其它電腦上能正常啟動執行。日誌中有時候會報資料庫連線超時,有時候會報類似於接連池問題。 Caused by: com.mysql.jdbc.exceptions.jdbc4.

spring-boot在啟動專案找不到Mapper。

最近在做spring-boot專案的時候出現了找不到mapper介面的問題,控制檯列印如下: *************************** APPLICATION FAILED TO START *************************** Descr

解決Eclipse中啟動Tomcat出現 Port 8080 required by Tomcat v8.0 Server at localhost is already in use...

解決方法: 1   找到佔用8080埠的程序,並結束程序。        1.Win+R  開啟執行 ,輸入cmd 開啟命令列視窗 。        2.假設要查詢埠808

Centos7 systemctl 啟動 firewalld 出現 Failed to start firewalld.service: Unit is masked.

也就是說這個命令被鎖著了,只需要執行如下命令: systemctl unmask firewalld 出現下面提示即可 Removed symlink /etc/systemd/system/firewalld.service 如果啥時候想鎖定他,執行下面命令即可:

GitHub Clone專案出現的問題(Permission denied (publickey))

GitHub Clone專案時出現的問題 在使用git在本地clone遠端Github上的專案時 root$ git clone [email protected]:XXXXX/XXXXX.git ... Warning: Permanently

匯入已有的Java Web專案出現關於javax.servlet的異常解決措施

1、Description Resource Path Location Type The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path 2、Descript

Android 匯入專案出現的各類錯誤(紅色感嘆號)

1、當import一個新的android專案時,專案名稱上出現一個紅色的感嘆號,程式不能執行。 原因:工程中classpath中指向的包路徑錯誤。 解決方法:在專案名稱上點右鍵選擇Properties,然後選擇Java Bulid Path中的libraries選項,其中出現紅色x號的路徑為錯誤路徑,刪除之