File tree Expand file tree Collapse file tree 1 file changed +28
-0
lines changed
packages/vue-i18n-core/test Expand file tree Collapse file tree 1 file changed +28
-0
lines changed Original file line number Diff line number Diff line change @@ -987,6 +987,34 @@ test('issue #1392', async () => {
987987 expect ( wrapper . html ( ) ) . toEqual ( `<div> component: works<br> t: works</div>` )
988988} )
989989
990+ test ( 'issue #1538' , async ( ) => {
991+ const i18n = createI18n ( {
992+ legacy : false ,
993+ locale : 'en' ,
994+ fallbackLocale : 'en' ,
995+ messages : {
996+ en : {
997+ 'my-message' : {
998+ the_world : 'the world' ,
999+ dio : 'DIO:' ,
1000+ linked : '@:my-message.dio @:my-message.the_world !!!!'
1001+ }
1002+ }
1003+ }
1004+ } )
1005+
1006+ const App = defineComponent ( {
1007+ setup ( ) {
1008+ const { t } = useI18n ( )
1009+ return { t }
1010+ } ,
1011+ template : `<div>{{ t('my-message.linked') }}</div>`
1012+ } )
1013+ const wrapper = await mount ( App , i18n )
1014+
1015+ expect ( wrapper . html ( ) ) . toEqual ( '<div>DIO: the world !!!!</div>' )
1016+ } )
1017+
9901018test ( 'issue #1547' , async ( ) => {
9911019 const i18n = createI18n ( {
9921020 legacy : false ,
You can’t perform that action at this time.
0 commit comments