question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`<em>` tags present inside arrays

See original GitHub issue

What’s wrong ?

Highlight doesn’t seem to work inside arrays.

Output on the dashboard: Capture d’écran 2021-07-05 à 15 35 24

Output from MeiliSearch:

    {
      "Title": "Brazilian Musicians",
      "Artist": "Tomas Santa Rosa Junior",
      "Nationality": [
        "Brazilian"
      ],
      "Gender": [
        "Male"
      ],
      "Date": "1941"
  }

What’s the expected behaviour ?

The element inside the array should either be highlighted, or not have the <em> tag

How to test

Use the Moma database:

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
mdubuscommented, Oct 12, 2021

Fixed with https://github.com/meilisearch/instant-meilisearch/pull/531 and the upgrade of instant-meilisearch

1reaction
mdubuscommented, Jul 6, 2021

Not sure about the bug you are talking about here. There indeed is a bug where the highlighted length of the tokens is invalid but I don’t think it is blocking you on this task. You can implement the highlighting of arrays. 😄

Sorry I heard that the highlight had a few problems with the v0.21, so I assumed that the problem came from there. After investigating further more, it seems to be caused by Instant MeiliSearch and not MeiliSearch itself.

I’ll have to wait for Instant MeiliSerch to be up-to-date with the v0.21 to see if it fixes the problem

Read more comments on GitHub >

github_iconTop Results From Across the Web

How do I insert HTML tags inside a Javascript array that ...
If you use an object you can get both the image name and description. You can then set both from that element in...
Read more >
Array methods - The Modern JavaScript Tutorial
Arrays provide a lot of methods. To make things easier, in this chapter they are split into groups. Add/remove items.
Read more >
Arrays in JavaScript - GeeksforGeeks
JavaScript array is a single variable that is used to store different elements. It is often used when we want to store a...
Read more >
Query an Array — MongoDB Manual
The following example queries for all documents where the field tags value is an array with exactly two elements, "red" and "blank" ,...
Read more >
What Is an Array Tag? - General Electric
You can query both an array tag and an element of the tag. Each element of the array tag will be displayed in...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found