Skip to main content
Version: Next

useSoftInputAppliedOffsetChanged

useSoftInputAppliedOffsetChanged is a shortcut for using AvoidSoftInput.onSoftInputAppliedOffsetChange method inside useEffect.

Parameters

TypeRequiredDescription
({ appliedOffset }: { appliedOffset: number }) => voidyesfunction called during applying padding or translation with current applied value

Example

import { useSoftInputAppliedOffsetChanged } from "react-native-avoid-softinput";

useSoftInputAppliedOffsetChanged(({ appliedOffset }) => {
// Do sth
});