silentmatt / expr-eval

Mathematical expression evaluator in JavaScript
http://silentmatt.com/javascript-expression-evaluator/
MIT License
1.18k stars 239 forks source link

Ignore case and support percentage #257

Open Sarmay opened 3 years ago

Sarmay commented 3 years ago

Hello! I like this library very much. Percentile is not supported in recent use, I want it to Judge% followed by numbers using Mod function, if there is no or operator using percentile/100; Also, doesn’t the library support case ignore? I use functions must be lowercase, uppercase or camel case writing is not recognized; Finally, I want it to support both PI and PI () ; currently PI () and PI can not exist simultaneously; Thank you very much!

你好!我非常喜欢这个函数库。 最近使用的时候发现不支持百分号,我想让它判断%后面是数字使用Mod函数,如果没有或者是运算符使用百分比/100; 还有,函数库不支持大小写忽略吗?我用函数的时候必须是小写,大写或者驼峰写法不识别; 最后一个问题,我想让它同时支持PI和PI();目前PI()和PI不能同时存在; 非常感谢!