locomotivemtl / locomotive-boilerplate

🚂 Front-end boilerplate for projects by Locomotive.
https://locomotivemtl-boilerplate.vercel.app/
MIT License
458 stars 71 forks source link

Add Sass functions #117

Closed lucasvallenet closed 2 years ago

lucasvallenet commented 2 years ago

Usefull SCSS functions

Usage:

z($) Use a z-index based on a scss list to keep control over each z-index values

strip-units($number) Strip unit from a number

sqrt($number) Square root function

pow($number, $exp) Power function

fact($number) Factorial function

pi() Pi reference

rad($angle) Convert deg to rad

sin($angle) Calculate the sinus of an angle

cos($angle) Calculate the cosinus of an angle

tan($angle) Calculate the tangent of an angle

arnvvd commented 2 years ago

Very good idea for the z-index function, I use scss vars to order my z-index list and it's a great thing 🙏

lucasvallenet commented 2 years ago

Comments updated and scripts reset