Skip to content
New issue

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

shape.digits #205

Merged
merged 5 commits into from
Dec 20, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
document _shape_.digits
  • Loading branch information
Fil committed Dec 19, 2022
commit d6d65e840e0327a30d047631a8edbe16c094a233
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ const l = d3.line();

Note: all the methods that accept arrays also accept iterables and convert them to arrays internally.

All the shapes described below expose a _shape_.digits([*digits*]) method. If *digits* is specified as a non-negative number, this method sets the precision (fractional digits) of the returned svg path, and returns the shape. If *digits* is not specified, it returns the precision, which defaults to 3.

### Arcs

[<img alt="Pie Chart" src="https://raw.githubusercontent.com/d3/d3-shape/master/img/pie.png" width="295" height="295">](http://bl.ocks.org/mbostock/8878e7fd82034f1d63cf)[<img alt="Donut Chart" src="https://raw.githubusercontent.com/d3/d3-shape/master/img/donut.png" width="295" height="295">](http://bl.ocks.org/mbostock/2394b23da1994fc202e1)
Expand Down