mirror of
https://github.com/cupcakearmy/svelte-i18n.git
synced 2024-06-30 18:54:49 +02:00
feat: add low level API to get access to the formatters (#31)
* Add test * Change approach, export functions to access the formatters instead
This commit is contained in:
parent
490fdd9492
commit
86cca99251
|
@ -21,6 +21,11 @@ export {
|
||||||
} from './stores/dictionary'
|
} from './stores/dictionary'
|
||||||
export { $isLoading as isLoading } from './stores/loading'
|
export { $isLoading as isLoading } from './stores/loading'
|
||||||
export { $format as format, $format as _, $format as t } from './stores/format'
|
export { $format as format, $format as _, $format as t } from './stores/format'
|
||||||
|
export {
|
||||||
|
getDateFormatter,
|
||||||
|
getNumberFormatter,
|
||||||
|
getTimeFormatter,
|
||||||
|
getMessageFormatter,
|
||||||
|
} from './includes/formatters'
|
||||||
// utilities
|
// utilities
|
||||||
export { registerLocaleLoader as register } from './includes/loaderQueue'
|
export { registerLocaleLoader as register } from './includes/loaderQueue'
|
||||||
|
|
|
@ -3,8 +3,8 @@ import {
|
||||||
getDateFormatter,
|
getDateFormatter,
|
||||||
getTimeFormatter,
|
getTimeFormatter,
|
||||||
getMessageFormatter,
|
getMessageFormatter,
|
||||||
} from '../../../src/client/includes/formatters'
|
init
|
||||||
import { init } from '../../../src/client/configs'
|
} from '../../../src/client'
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
init({ fallbackLocale: undefined })
|
init({ fallbackLocale: undefined })
|
||||||
|
|
Loading…
Reference in New Issue
Block a user