Skip to content

Commit cea1988

Browse files
ktsnyyx990803
authored andcommitted
use state transformer in logger plugin (vuejs#309)
1 parent a475456 commit cea1988

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/plugins/logger.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@ export default function createLogger ({
2828
console.log(message)
2929
}
3030

31-
console.log('%c prev state', 'color: #9E9E9E; font-weight: bold', prevState)
31+
console.log('%c prev state', 'color: #9E9E9E; font-weight: bold', transformer(prevState))
3232
console.log('%c mutation', 'color: #03A9F4; font-weight: bold', formattedMutation)
33-
console.log('%c next state', 'color: #4CAF50; font-weight: bold', nextState)
33+
console.log('%c next state', 'color: #4CAF50; font-weight: bold', transformer(nextState))
3434

3535
try {
3636
console.groupEnd()

0 commit comments

Comments
 (0)