We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support standard sprintf notation with this library: http://www.diveintojavascript.com/projects/javascript-sprintf
template = "{{followers/following%0.2f}}" # round to two decimals
We'll want to build in sensible defaults too.
We'll also want to add in a shorthand notation for rounding (will be the most common operation by far):
"{{expression%0}}" => round to whole "{{expression%n}}" => round nth decimal
Anyone that's worried about padding can use the sprintf notation.
The text was updated successfully, but these errors were encountered:
For shorthand notation we can just rely on javascript's toFixed method.
toFixed
Sorry, something went wrong.
No branches or pull requests
Support standard sprintf notation with this library: http://www.diveintojavascript.com/projects/javascript-sprintf
We'll want to build in sensible defaults too.
We'll also want to add in a shorthand notation for rounding (will be the most common operation by far):
Anyone that's worried about padding can use the sprintf notation.
The text was updated successfully, but these errors were encountered: