新しいReact Nativeプロジェクトを作成し、プロジェクトに@ shoutem/uiをインストールし、Shoutem UIのExamplesコンポーネントをReact Nativeアプリに含めます。不明な名前付きモジュール: 'react/lib/NativeMethodsMixin'
import React, { Component } from 'react';
import { AppRegistry } from 'react-native';
import { Examples } from '@shoutem/ui';
class HelloWorld extends Component {
render() {
return (
<Examples />
);
}
}
AppRegistry.registerComponent('HelloWorld',() => HelloWorld);
しかし、私はプロジェクトを開始する実行したとき、私は「不明という名前のモジュールを: 『/ libに/ NativeMethodsMixin反応する』」を取得エラー。 https://github.com/shoutem/animation/blob/develop/Parallax.js NativeMethodsMixin
react
から正しくインポートされていません:
あなたはこの変更した場合:これに import NativeMethodsMixin from 'react/lib/NativeMethodsMixin';
を:
ありがとうございます。 – Kais