@@ -9,7 +9,7 @@ Now we have solved this problem for you. We have designed a simple and easy-to-u
99- 🔒 ** Secure by default** - No access to global objects or prototype chain, does not use ` eval ` or ` new Function `
1010- 🚀 ** High performance** - Supports pre-compilation of expressions for improved performance with repeated evaluations
1111- 🛠️ ** Extensible** - Register custom functions to easily extend functionality
12- - 🪩 ** Lightweight** - Zero dependencies, small footprint, only 7.8KB
12+ - 🪩 ** Lightweight** - Zero dependencies, small footprint, only ` 7.8KB `
1313
1414## Installation
1515
@@ -184,6 +184,27 @@ Performance comparison of different evaluation methods: (baseline: new Function)
184184| Medium Expressions | 2.16x faster | 9.81x faster | 37.81x faster |
185185| Complex Expressions | 1.59x faster | 4.89x faster | 32.74x faster |
186186
187+ ``` mermaid
188+ gantt
189+ title Performance Comparison (Baseline: new Function)
190+ dateFormat X
191+ axisFormat %s
192+
193+ section Simple
194+ evaluate after compile :done, 0, 159
195+ evaluate without compile :done, 0, 636
196+ expr-eval Parser :done, 0, 2394
197+
198+ section Medium
199+ evaluate after compile :done, 0, 216
200+ evaluate without compile :done, 0, 981
201+ expr-eval Parser :done, 0, 3781
202+
203+ section Complex
204+ evaluate after compile :done, 0, 159
205+ evaluate without compile :done, 0, 489
206+ expr-eval Parser :done, 0, 3274
207+ ```
187208
188209## Advanced Usage
189210
0 commit comments