How to use the reakit-utils/isEmpty.isEmpty function in reakit-utils

To help you get started, we’ve selected a few reakit-utils examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github reakit / reakit / packages / reakit / src / Form / __utils / hasMessages.ts View on Github external
export function hasMessages(errors: any) {
  return isObject(errors) && !isEmpty(errors);
}
github reakit / reakit / packages / reakit / src / Form / FormState.ts View on Github external
function getMessages(
  stateMessages: Messages,
  actionMessages: Messages
) {
  return !isEmpty(actionMessages)
    ? actionMessages
    : isEmpty(stateMessages)
    ? stateMessages
    : {};
}
github reakit / reakit / packages / reakit / src / Form / FormState.ts View on Github external
function getMessages(
  stateMessages: Messages,
  actionMessages: Messages
) {
  return !isEmpty(actionMessages)
    ? actionMessages
    : isEmpty(stateMessages)
    ? stateMessages
    : {};
}