math-expressions icon indicating copy to clipboard operation
math-expressions copied to clipboard

Support for physical units?

Open Chris1234567899 opened this issue 2 years ago • 1 comments

Great package - are you planning to support physical units in this package? Like area, length, mass, etc...? There is a great JS library which allows for quite "complex" calculations like evaluate('10km/h > 17m/3s'). And even allows the creation of custom units. https://mathjs.org/docs/datatypes/units.html

It would be awesome to have something similar in dart.

Chris1234567899 avatar Jul 28 '22 21:07 Chris1234567899

Thanks for the suggestion, I like the idea!

Support for units wasn't a consideration during development of this library which has a pretty narrow scope so far. Implementing this would likely require some rather large changes to the way the library works internally.

However, I'll leave this ticket open as an enhancement request for future consideration, or for somebody else to pick up :)

fkleon avatar Jul 29 '22 09:07 fkleon