小编Rek*_*kin的帖子

将 react-native 组件与 vue-native 结合

有什么办法可以将像https://github.com/archriss/react-native-snap-carousel/tree/master/example这样的 react native 组件与 vue native结合起来?

我有一个 vue-native 项目,想在其中使用 react-native 组件,但我有一个我不明白的错误:控制台说: Invariant Violation: expected a string (for built-in components) or a class/function (for composite components) but got: undefined

<template>
  <nb-container>
    <nb-content>
              <carousel
                :data="similarEventsData"
                :renderItem="_renderItem"
                :sliderWidth="sliderWidth"
                :itemWidth="itemWidth"
                :inactiveSlideScale="0.95"
                :inactiveSlideOpacity="1"
                :enableMomentum="true"
                :activeSlideAlignment="'start'"
                :containerCustomStyle="stylesObj.slider"
                :contentContainerCustomStyle="stylesObj.sliderContentContainer"
                :activeAnimationType="'spring'"
                :activeAnimationOptions="{ friction: 4, tension: 40 }"
              />
    </nb-content>
  </nb-container>
</template>

<script>
import { Dimensions, Platform, Share } from "react-native";
import Carousel from 'react-native-snap-carousel';
import { scrollInterpolators, animatedStyles } from '../../utils/animations';

const { width: viewportWidth, height: …
Run Code Online (Sandbox Code Playgroud)

react-native vue-native

6
推荐指数
1
解决办法
410
查看次数

标签 统计

react-native ×1

vue-native ×1