quarto-dev / quarto-dev/quarto-cli
Suggestion: Add builtin support for SI unit formatting
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 6k
- Forks
- 458
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 41
Description
Hey everyone,
Has there been discussion about adding some sort of SI unit formatting to quartio, similar to what siunitx allows for LaTeX?
This sort of thing is quite helpful when working with derived SI units, or prefixes that aren't found on latin keyboards. siunitx (documentation here) handles this in LaTeX, and it would be nice to somehow bring this functionality over.
siunitx ensures that the units are formatted consistently, with a required nonbreaking space between number and unit. It also has some nice features for things like formatting angles, lists, and ranges. As examples, \qty{30}{\uA} is rendered as "30 µA", \qty{70}{\Mohm\per\um} as "70 MΩ µm^-1" (with the correct exponent of course), \ang{180} as "180°" , or \qtyrange{0.15}{30}{\MHz} as "0.15 MHz to 30 MHz. (There are a lot more examples in the PDF documentation linked above).
Something like this would be a very nice fit for Quarto's use in scientific documentation.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked siunitx documentation and the examples in the issue, then determine the intended scope for bringing SI quantities, angles, lists, and ranges to Quarto. The issue names no source files or tests; the work is done when the agreed formatting behavior, including nonbreaking spaces and derived-unit exponents, is supported and verified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- latex
- Domain
- documentation
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100