Node Script

Number to String three Decimals

Downloads: 40
Download
Ads Support FTD

Description

Converts a number to a string while keeping 3 decimals

//
// NumberToStringThreeDecimals.ts
// Converst a Number to a String while keeping three decimal places
// Written by @Fusedthreed – https://FusedThreeD.com
//

@customNode()
export class NumberToStringThreeDecimals extends BasicScriptNode {

  @input()
  number: number;

  @output()
  string: string;

  execute() {
    this.string = this.number.toFixed(3).toString();
  }
}
Ads Support FTD