3

I've spent all day and night battling with Search API (with and without Apache Solr) in Drupal 8.

Does anyone know if you can use Search API to index paragraph content and then in a search views result, get back the "excerpt" of highlighted text from within a paragraph + the title of the node the paragraph is used in?

4
  • 1
    What exactly do you have working and what doesn't? The paragraph demo module contains an example search index that indexes paragraphs and works. It is a bit tedious to set up, when you want to use field based indexing, you need to add every possible path of paragraphs and fields. Or you can index the rendered entity, then it should work fine but might be slower to index
    – Berdir
    Commented Dec 1, 2016 at 20:51
  • I think he means he wants to be able to index paragraph fields so that excerpts based on them are possible. I have had similar questions in regards to searching across paragraphs, as well as adding them for scoring/boosting in Solr.
    – Kevin
    Commented Jan 26, 2017 at 19:26
  • @Kevin – You have a link to that question?
    – leymannx
    Commented Nov 13, 2019 at 8:03
  • any update on this? looking solution for similar problem.
    – mks
    Commented Apr 15, 2020 at 10:32

1 Answer 1

0

If you add the specific fields within your paragraphs to search_api fields it will generate excerpts for them. If you just have 'Rendered HTML' of the entire page, it will not create excerpts of paragraph text.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.