1.2.0
What's Changed
config.debug
has been replaced byconfig.log
object:
const config = {
// ...your config...
log: {
logger: console, // you can use custom loggers => { error: errorHandler, warn: warnHandler, debug: debugHandler }
level: 'warn', // 'error' | 'warn' | 'debug'
prefix: '[i18n]: ', // avoid by '' (empty string)
}
}
- Added
config.fallbackValue
. By default translation key is returned when no translations have been found for given translation key. You can override it using this parameter like so:
const config = {
// ...your config...
fallbackValue: undefined, // this will return `undefined` instead of unknown translation key...
}
Full Changelog: 1.1.3...1.2.0