Skip to content

Commit

Permalink
feat(vue): fix vue replace &nbsp
Browse files Browse the repository at this point in the history
  • Loading branch information
zealotchen0 authored and hippy-actions[bot] committed Apr 16, 2024
1 parent c723688 commit b858402
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions driver/js/packages/hippy-vue/src/util/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -243,9 +243,9 @@ function whitespaceFilter(str: string) {
// "trimWhitespace": default behavior is true.
// It will trim leading / ending whitespace including all special unicode such as \xA0( ).
if (!_Vue || typeof _Vue.config.trimWhitespace === 'undefined' || _Vue.config.trimWhitespace) {
return str.trim().replace(/Â/g, ' ');
return str.trim().replace(/( |Â)/g, ' ');
}
return str.replace(/Â/g, ' ');
return str.replace(/( |Â)/g, ' ');
}

export {
Expand Down

0 comments on commit b858402

Please sign in to comment.