-
Notifications
You must be signed in to change notification settings - Fork 208
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor: remove lodash #1949
refactor: remove lodash #1949
Conversation
Replace lodash with native ES2015 functions (#1871) Co-authored-by: Jo Liss <[email protected]>
import { tokenStructuredMatcher } from "../../scan/tokens" | ||
|
||
// ES2019 Array.prototype.flatMap | ||
function flatMap<U, R>(arr: U[], callback: (x: U, idx: number) => R[]): R[] { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TODO: extract to utils
/ functional-utils
file
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or maybe change the compilation target to ES2019?
However, compilation target changes should be done in a separate PR, so the extraction to utils should still be done...
3c721fb
to
fbfeab6
Compare
Seems like a ~6% performance regression in the JSON lexer benchmark. |
Dropping this, will evaluate remda instead. |
No description provided.