mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-20 21:31:32 +02:00
math: Add trigonometric functions and some angle helper functions
This commit adds these new template functions in the `math` namespace: math.Acos math.Asin math.Atan math.Atan2 math.Cos math.Pi math.Sin math.Tan math.ToDegrees math.ToRadians Co-authored-by: Joe Mooring <joe@mooring.com>
This commit is contained in:
19
docs/content/en/functions/math/ToDegrees.md
Normal file
19
docs/content/en/functions/math/ToDegrees.md
Normal file
@@ -0,0 +1,19 @@
|
||||
---
|
||||
title: math.ToDegrees
|
||||
description: ToDegrees converts radians into degrees.
|
||||
categories: []
|
||||
keywords: []
|
||||
action:
|
||||
aliases: []
|
||||
related:
|
||||
- functions/math/ToRadians
|
||||
- functions/math/Pi
|
||||
returnType: float64
|
||||
signatures: [math.ToDegrees VALUE]
|
||||
---
|
||||
|
||||
{{< new-in 0.130.0 >}}
|
||||
|
||||
```go-html-template
|
||||
{{ math.ToDegrees 1.5707963267948966 }} → 90
|
||||
```
|
Reference in New Issue
Block a user