fix: getPointAtLength signature

make first parameter a number instead of options object
This commit is contained in:
Mikael Sand
2019-10-04 16:43:25 +03:00
parent 2ba64df7cb
commit 2c57af2f2c

View File

@@ -108,11 +108,11 @@ export default class Shape<P> extends Component<P> {
const handle = findNodeHandle(this.root as Component);
RNSVGRenderableManager.getTotalLength(handle, callback);
};
getPointAtLength = (options: Object, callback: () => void) => {
getPointAtLength = (length: number, callback: () => void) => {
if (!callback) {
return;
}
const handle = findNodeHandle(this.root as Component);
RNSVGRenderableManager.getPointAtLength(handle, options, callback);
RNSVGRenderableManager.getPointAtLength(handle, { length }, callback);
};
}