Tôi đã đọc các blog sau đây và tài liệuChuyển 4.x góc tới góc 5
và không có thông tin rõ ràng về cách di chuyển từ 4 .x đến 5.
Đã thử các lệnh sau
NPM cài đặt
npm install @angular/{animations,common,compiler,compiler-cli, core,forms,http,platform-browser,platform-browser-dynamic, platform-server,router}@5.0.0
lắp đặt sợi
yarn add @angular/{animations,common,compiler,compiler-cli, core,forms,http,platform-browser,platform-browser-dynamic, platform-server,router}@5.0.0
thử các update guide
npm install @angular/[email protected]'^5.0.0' @angular/[email protected]'^5.0.0' @angular/[email protected]'^5.0.0' @angular/[email protected]'^5.0.0' @angular/[email protected]'^5.0.0' @angular/[email protected]'^5.0.0' @angular/[email protected]'^5.0.0' @angular/[email protected]'^5.0.0' @angular/[email protected]'^5.0.0' @angular/[email protected]'^5.0.0' @angular/[email protected]'^5.0.0' [email protected] [email protected]'^5.5.2' npm install [email protected] --save-exact
Không có gì hiệu quả với tôi. Xin vui lòng giúp
Khi bạn nói 'không có gì hoạt động', ý của bạn là gì? Bạn có bất kỳ lỗi nào không? Đối với lệnh từ hướng dẫn cập nhật, tôi đã xóa tất cả dấu ngoặc đơn giữa gói và phiên bản: https://github.com/StephenFluin/angular-update-guide/issues/4 – Kevin
Bạn cũng có thể chỉnh sửa package.json của mình và sau đó chạy 'npm install'. '" phụ thuộc ": { " @ góc/hình động ":" 5.0.0 ", " @ góc/chung ":" 5.0.0 ", " @ góc/trình biên dịch ":" 5.0.0 ", "@ góc/lõi": "5.0.0", "@ góc/biểu mẫu": "5.0.0", "@ góc/http": "5.0.0", "@ góc cạnh/nền tảng-trình duyệt" : "5.0.0", "@ góc/nền tảng-trình duyệt-động": "5.0.0", "@ góc/bộ định tuyến": "5.0.0", ' – MatthiasSommer
Có hướng dẫn nâng cấp của nhóm Góc có sẵn [ở đây] (https://angular-update-guide.firebaseapp.com/). – JayChase