vue-iscroll-view
vue-iscroll-view copied to clipboard
TypeError: r is not a constructor
Testing.vue:
<template>
<iscroll-view class="scroll-view">
Your contents
</iscroll-view>
</template>
<script>
import Vue from 'vue'
import IScrollView from 'vue-iscroll-view'
import IScroll from 'iscroll'
Vue.use(IScrollView, IScroll)
</script>
<style>
.scroll-view {
/* -- Attention: This line is extremely important in chrome 55+! -- */
touch-action: none;
/* -- Attention-- */
position: fixed;
top: 0;
bottom: 0;
left: 0;
right: 0;
overflow: hidden;
}
</style>
Getting the following error:
[Vue warn]: Error in nextTick: "TypeError: r is not a constructor"
found in
---> <IscrollView>
<Testing> at src/renderer/components/Testing.vue
<TestingVueIscrollView> at src/renderer/App.vue
<Root>
warn @ vue.esm.js?efeb:591
logError @ vue.esm.js?efeb:1737
globalHandleError @ vue.esm.js?efeb:1732
handleError @ vue.esm.js?efeb:1721
(anonymous) @ vue.esm.js?efeb:1839
flushCallbacks @ vue.esm.js?efeb:1758
vue.esm.js?efeb:1741 TypeError: r is not a constructor
at VueComponent.<anonymous> (/opt/projects/testvueiscrollview/node_modules/vue-iscroll-view/index.js:1)
at Array.eval (vue.esm.js?efeb:1837)
at flushCallbacks (vue.esm.js?efeb:1758)
at <anonymous>
logError @ vue.esm.js?efeb:1741
globalHandleError @ vue.esm.js?efeb:1732
handleError @ vue.esm.js?efeb:1721
(anonymous) @ vue.esm.js?efeb:1839
flushCallbacks @ vue.esm.js?efeb:1758
TypeError: r is not a constructor
at VueComponent.<anonymous> (/opt/projects/testvueiscrollview/node_modules/vue-iscroll-view/index.js:1)
at Array.eval (vue.esm.js?efeb:1837)
at flushCallbacks (vue.esm.js?efeb:1758)
at <anonymous>
logError @ vue.esm.js?efeb:1741
globalHandleError @ vue.esm.js?efeb:1732
handleError @ vue.esm.js?efeb:1721
(anonymous) @ vue.esm.js?efeb:1839
flushCallbacks @ vue.esm.js?efeb:1758
环境问题,把node_modules删除掉重新下载