This repository has been archived by the owner on Dec 30, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 157
Null attributes causes the highlight component to throw errors #385
Comments
I think at a very minimum, the error message should be clarified, because it sent me down the wrong path for an hour or two trying to figure out why it wasn't "configured for highlighting". |
Seems like in your case, just changing that error to “might” and into a warning should be enough I think |
Feel free to make a PR to any text you’d prefer! |
I think that better solution is for the |
Haroenv
added a commit
that referenced
this issue
Feb 1, 2018
Haroenv
added a commit
that referenced
this issue
Feb 2, 2018
I also have the same issue for null attributes to be highlighted. |
Haroenv
added a commit
to algolia/instantsearch
that referenced
this issue
Dec 28, 2022
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Do you want to request a feature or report a bug?
Bug.
Bug: What is the current behavior?
I have homeowner records in Algolia, and sometimes the
owner_name
can beNULL
, when that's the case, theais-highlight
will throw this error over and over:Error in render: "Error: The "owner_name" attribute is currently not configured to be highlighted in Algolia. See https://www.algolia.com/doc/api-reference/api-parameters/attributesToHighlight/."
Bug: What is the expected behavior?
No text is displayed for that attribute, no error is thrown. The attribute is set up for searching, one or two records just have null values!
Bug: What browsers are impacted? Which versions?
All
Bug: What is the proposed solution?
Not sure... Change this check to something more strict though: https://github.com/algolia/vue-instantsearch/blob/master/src/components/Highlight.js#L22
The text was updated successfully, but these errors were encountered: