We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 29541b8 commit 0ca838eCopy full SHA for 0ca838e
1 file changed
nativescript-core/ui/text-base/span.ts
@@ -65,8 +65,9 @@ export class Span extends ViewBase implements SpanDefinition {
65
}
66
set text(value: string) {
67
if (this._text !== value) {
68
- this._text = value && value.replace("\\n", "\n").replace("\\t", "\t");
69
- this.notifyPropertyChange("text", value);
+ // value can be a number
+ this._text = `${value}`.replace("\\n", "\n").replace("\\t", "\t");
70
+ this.notifyPropertyChange("text", this._text);
71
72
73
0 commit comments