Skip to content

Commit f332bee

Browse files
nifteadamwathan
andauthored
Update color warnings to match other warnings (#5412)
* Update color warnings to match other warnings Make the color deprecation warnings match the style of other warnings in tailwind * Fix formatting * Use log helper Co-authored-by: Adam Wathan <[email protected]>
1 parent 7859cee commit f332bee

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

colors.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
1+
const log = require('./lib/util/log').default
2+
13
let warned = []
24

35
function warn({ version, from, to }) {
46
if (!warned.includes(from)) {
5-
console.log(`warn - As of Tailwind CSS ${version}, \`${from}\` has been renamed to \`${to}\`.`)
6-
console.log('warn - Please update your color palette to eliminate this warning.')
7+
log.warn([
8+
`As of Tailwind CSS ${version}, \`${from}\` has been renamed to \`${to}\`.`,
9+
'Please update your color palette to eliminate this warning.',
10+
])
711
warned.push(from)
812
}
913
}

0 commit comments

Comments
 (0)