【发布时间】:2019-09-11 21:58:09
【问题描述】:
我需要将简单的上传输入字段更改为“拖放”上传。
我做了一些研究,但没有找到关于 Angular 5 的任何线索。我尝试使用 ngx-file-drop,但遇到了兼容性错误。
@angular/compiler-cli@5.2.11 requires a peer of typescript@>=2.4.2 <2.7 but none is installed. You must install peer dependencies yourself.
npm WARN ngx-file-drop@6.0.0 requires a peer of @angular/common@^7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN ngx-file-drop@6.0.0 requires a peer of @angular/platform-browser@^7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN ngx-file-drop@6.0.0 requires a peer of @angular/platform-browser-dynamic@^7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN ngx-file-drop@6.0.0 requires a peer of rxjs@^6.3.3 but none is installed. You must install peer dependencies yourself.
我想查看 Angular 5 项目中拖放的示例和实现。
【问题讨论】:
-
这些依赖警告就是它们的本来面目,警告。如果没有错误,您可以安全地使用它。或者安装旧版本的 ngx-file-drop,它确实支持 angular 5。
标签: angular typescript angular5