@electron-forge/core
Version:
A complete tool for building modern Electron applications
18 lines (15 loc) • 400 B
text/typescript
import chalk from 'chalk';
import logSymbols from 'log-symbols';
type Deprecation = {
replaceWith: (replacement: string) => void;
};
export default (what: string): Deprecation => ({
replaceWith: (replacement: string): void => {
console.warn(
logSymbols.warning,
chalk.yellow(
`WARNING: ${what} is deprecated, please use ${replacement} instead`,
),
);
},
});