'use strict';

var React = require('react');
var TableContext = require('../TableContext.cjs');

const useTable = () => {
    const ctx = React.useContext(TableContext.TableContext);
    if (ctx === null) {
        throw new Error("useTable must be used inside of a TableContext.Provider");
    }
    return ctx;
};

exports.useTable = useTable;
//# sourceMappingURL=useTable.cjs.map
