angularjs4升级了,原来的animations现在被单独出来一个包。
package.json中添加
"dependencies": {
"@angular/animations":
"^4.0.1",
}
npm install
在相应的模块或者app.module.ts中添加
import {
BrowserAnimationsModule }
from
'@angular/platform-browser/animations';
imports: [
BrowserAnimationsModule
],