首页 > 解决方案 > ngx-swiper-wrapper 是否适用于 Angular 7?

问题描述

我正在从 Angular 5 迁移到 Angular 7。

我的项目包含ngx-swiper-wrapper https://github.com/zefoy/ngx-swiper-wrapper]

使用 Angular 7运行ng build --prod,报告错误

错误模块构建失败(来自 ./node_modules/sass-loader/lib/loader.js):

导入{$,addClass,removeClass,hasClass,toggleClass,attr,removeAttr,data,transform,transition as transition$1,on,off,trigger,transitionEnd as transitionEnd$1,outerWidth,outerHeight,offset,css,each,html,text, is, index, eq, append, prepend, next, nextAll, prev, prevAll, parent, parents, nearest, find, children, remove, add, styles } from 'dom7/dist/dom7.modular'; ^ "import {": 预期 "}" 之后的无效 CSS,在 /home/victor/src/sabre/sabre-desktop/node_modules/swiper/dist/js/swiper.esm.bundle 中为 "$, addClass, remove"。 js(第 13 行,第 9 列)

我该如何解决这种情况?

标签: angularangular7

解决方案


推荐阅读