You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm not sure whether this should be dealt with by vdom or by i18n lib, I prefer the latter. Nonetheless, for this particular functional component, I think only element nodes (nodeType === 1) should be considered. Since plain text can be easily moved to i18n message object.
The text was updated successfully, but these errors were encountered:
vue & vue-i18n version
vue: 2.4.2
vue-i18n: 7.1.1
Reproduction Link
https://jsbin.com/hohalimepo/edit?html,js,output
What is Expected?
Both should render correct sentence.
What is actually happening?
The first one parses line break as a VNode
So that the second slot in i18n string was replaced with the
TextNode
, which was the line break between two child elements.I have to now write it like this.
I'm not sure whether this should be dealt with by vdom or by i18n lib, I prefer the latter. Nonetheless, for this particular functional component, I think only element nodes (
nodeType === 1
) should be considered. Since plain text can be easily moved to i18n message object.The text was updated successfully, but these errors were encountered: