securityos/node_modules/framer-motion/dist/es/utils/errors.mjs

19 lines
416 B
JavaScript
Raw Permalink Normal View History

2024-09-06 15:32:35 +00:00
import { noop } from './noop.mjs';
let warning = noop;
let invariant = noop;
if (process.env.NODE_ENV !== "production") {
warning = (check, message) => {
if (!check && typeof console !== "undefined") {
console.warn(message);
}
};
invariant = (check, message) => {
if (!check) {
throw new Error(message);
}
};
}
export { invariant, warning };