Désactive les warnings en prod

pull/1278/head
Johan Girod 2020-12-14 10:52:31 +01:00 committed by Johan Girod
parent 96e512f2f2
commit 339c534183
1 changed files with 4 additions and 3 deletions

View File

@ -63,13 +63,14 @@ export function warning(
message: string,
solution?: string
) {
console.warn(
`\n[ Avertissement ]
process.env.NODE_ENV !== 'production' &&
console.warn(
`\n[ Avertissement ]
Dans la règle \`${coerceArray(rules).slice(-1)[0]}\`
${message}
💡 ${solution ? solution : ''}
`
)
)
}
export class InternalError extends EngineError {