Jetpack: Instant Search: Can't add spaces after typing a number query

Created on 20 Feb 2020  路  1Comment  路  Source: Automattic/jetpack

Reported in https://github.com/Automattic/jetpack/pull/14692#issuecomment-587919478.

Steps to reproduce the issue

  1. Setup Jetpack Instant Search on your site.
  2. Search your site to trigger the search overlay.
  3. Enter a purely numerical search query, like 123.
  4. Try typing 123 main street.

What I expected

A search executes for 123 main street.

What happened instead

Unable to type 123.

Instant Search Search [Type] Bug

Most helpful comment

As mentioned in the original comment, this is happening because qss automatically typecasts Booleans and Numbers. In this case specifically, it's typecasting "1 " as 1 which is then cast into "1" in the Instant Search client.

I opened a PR in the library for toggling typecasting here: lukeed/qss/pull/8.

>All comments

As mentioned in the original comment, this is happening because qss automatically typecasts Booleans and Numbers. In this case specifically, it's typecasting "1 " as 1 which is then cast into "1" in the Instant Search client.

I opened a PR in the library for toggling typecasting here: lukeed/qss/pull/8.

Was this page helpful?
0 / 5 - 0 ratings