UNPKG

@primer/react

Version:

An implementation of GitHub's Primer Design System using React

15 lines (14 loc) 320 B
//#region src/utils/warning.ts const warn = function warn(message) { console.warn("Warning:", message); }; const warning = function warning(condition, format, ...args) { if (condition) { let index = 0; warn(format.replace(/%s/g, () => { return args[index++]; })); } }; //#endregion export { warn, warning };