mirror of
https://github.com/zoriya/react-native-svg.git
synced 2026-06-02 06:35:04 +00:00
use createReactNativeComponentClass inside from react
due to the peerDependency of react-native is >=0.29.0. so there is no need to consider compatibility with react-native@0.27.0 and below.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import React, {Component, PropTypes} from 'react';
|
||||
import {set, remove} from '../lib/extract/extractClipping';
|
||||
import createNativeComponent from '../lib/createNativeComponent';
|
||||
import createReactNativeComponentClass from 'react/lib/createReactNativeComponentClass';
|
||||
import {ClipPathAttributes} from '../lib/attributes';
|
||||
|
||||
class ClipPath extends Component{
|
||||
static displayName = 'ClipPath';
|
||||
@@ -32,7 +33,10 @@ class ClipPath extends Component{
|
||||
}
|
||||
}
|
||||
|
||||
const RNSVGClipPath = createNativeComponent('RNSVGClipPath');
|
||||
const RNSVGClipPath = createReactNativeComponentClass({
|
||||
validAttributes: ClipPathAttributes,
|
||||
uiViewClassName: 'RNSVGClipPath'
|
||||
});
|
||||
|
||||
export default ClipPath;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user