Skip to content
Permalink
Browse files

Add deprecation warning while importing Slider component (#23385)

Summary:
Introducing the deprecation warning for those who are importing `Slider` component (#23313)

[General] [Deprecated] - Deprecated Slider as it has now been moved to `react-native-community/slider`
Pull Request resolved: #23385

Differential Revision: D14029819

Pulled By: cpojer

fbshipit-source-id: 7ad257124756c6bee57c3fbb1a056c09e8cc29a1
  • Loading branch information...
michalchudziak authored and facebook-github-bot committed Feb 11, 2019
1 parent ffe3748 commit bf888a7582763a593d8b36874d242653fc0a9575
Showing with 6 additions and 0 deletions.
  1. +6 −0 Libraries/react-native/react-native-implementation.js
@@ -104,6 +104,12 @@ module.exports = {
return require('SegmentedControlIOS');
},
get Slider() {
warnOnce(
'slider-moved',
'Slider has been extracted from react-native core and will be removed in a future release. ' +
"It can now be installed and imported from '@react-native-community/slider' instead of 'react-native'. " +
'See https://github.com/react-native-community/react-native-slider',
);
return require('Slider');
},
get SnapshotViewIOS() {

0 comments on commit bf888a7

Please sign in to comment.
You can’t perform that action at this time.