Skip to content

Conversation

@tkieft
Copy link

@tkieft tkieft commented Sep 23, 2022

Specifying a query with a regex special character causes ninja-keys to throw an exception. For example, imagine searching a phone number "+13155550000".

To fix, we escape the search query before constructing the regex.

},
"dependencies": {
"@material/mwc-icon": "0.25.3",
"escape-string-regexp": "5.0.0",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding another library would probably make it a bit slower, is there a way to do this without external libraries?

@KonnorRogers
Copy link

It appears this package hasn't had any comments or any releases in ~2 years. I made a fork with quite a few accessibility improvements and other changes noted in the changelog. Adding this to my package as well.

Fixed in my fork here: KonnorRogers/konnors-ninja-keys#9

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants