/**
 * @license MIT
 * author: Cube Dev Team
 * @cube-dev/ui-kit v0.0.0-canary-9f08182
 * Released under the MIT license.
 */

import { useContext } from 'react';
import invariant from 'tiny-invariant';
import { NotificationsContext } from '../NotificationsContext/index.js';
export function useNotificationsApi() {
    const context = useContext(NotificationsContext);
    invariant(context !== null, "You can't use Notifications outside of the <Root /> component. Please, check if your component is descendant of <Root/> component");
    return context.api;
}

        