Button Does Not Work (Native component for "MKTouchable"/"Tickview" does not exist)
See original GitHub issueWhen running I receive the 2 warnings mentioned in the subject and the button does not react when clicked: no visual feedback and the console.log in the onPress event is not executed. (I tried on iOS simulator).
I used the following code copy pasted from the documentation example:
const MK = require('react-native-material-kit');
const {
MKButton,
MKColor,
MKTouchable
} = MK;
...
<MKButton
backgroundColor={MKColor.Red}
shadowRadius={2}
shadowOffset={{width:0, height:2}}
shadowOpacity={.7}
shadowColor="black"
onPress={() => {
console.log('hi, raised button!');
}}
>
<Text pointerEvents="none"
style={{color: 'red', fontWeight: 'bold',}}>
RAISED BUTTON
</Text>
</MKButton>
Warnings:
ExceptionsManager.js:78Warning: Native component for "MKTouchable" does not existreactConsoleError @ ExceptionsManager.js:78console.error @ YellowBox.js:49warning @ warning.js:42requireNativeComponent @ requireNativeComponent.js:53(anonymous function) @ MKTouchable.js:62requireImpl @ require.js:61require @ require.js:21(anonymous function) @ Ripple.js:12requireImpl @ require.js:61require @ require.js:21(anonymous function) @ IconToggle.js:20requireImpl @ require.js:61require @ require.js:21(anonymous function) @ index.js:5requireImpl @ require.js:61require @ require.js:21(anonymous function) @ index.js:7requireImpl @ require.js:61require @ require.js:21(anonymous function) @ screen-lovers-profile.js:3requireImpl @ require.js:61require @ require.js:21(anonymous function) @ main.js:9requireImpl @ require.js:61require @ require.js:21(anonymous function) @ index.ios.js:4requireImpl @ require.js:61requireImpl @ require.js:29require @ require.js:21(anonymous function) @ index.ios.js.js:1messageHandlers.executeApplicationScript @ debuggerWorker.js:18onmessage @ debuggerWorker.js:33
ExceptionsManager.js:78Warning: Native component for "TickView" does not exist
Any ideas?
Thanks!
Issue Analytics
- State:
- Created 8 years ago
- Comments:16
Top Results From Across the Web
"Warning: Native component for <component> does not exist ...
Another scenario this error occurs is when installing a new native package. Make sure to: run yarn: yarn install; run cocoapods: pod install...
Read more >Handling Events - React
React events do not work exactly the same as native events. ... For example, this Toggle component renders a button that lets the...
Read more >Icon button - Carbon Design System
Buttons are used to initialize an action. Button labels express what action will occur when the user interacts with it.
Read more >Building a Button Part 1: Press Events – React Spectrum Blog
This is not how native buttons behave, so it can feel inconsistent with user expectations. Pointer events#. The pointer events spec is designed ......
Read more >How to create and style custom buttons in React Native
It allows you to build apps that will work on both iOS and Android platforms, but core UI components such as <Button />...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Works great with Redux. And made to do so. Hope this helps you @AndrewHenderson https://habd.as/awesome-react-boilerplates
If anyone else reads this chain, I resolved it by rebuilding my Xcode project and the linking took care of the rest. As others have mentioned, the linking doesn’t take effect until you rebuild.