score:2

Accepted answer

You would need to wrap the code inside that div in curly braces { } to be valid JSX. Just like you did with the first chunks.map.

return(
        <div className="tile is-ancestor">
               {chunks.map((chunk)=> {
                 return (
                   <div class="tile">
                    {
                      chunk.map((edge) => {
                          return(
                            <div className="tile is-parent is-4">
                              <div className={`tile is-child notification ${edge.node.frontmatter.type}`}>
                              <p className="is-7">{edge.node.frontmatter.date}</p>
                              <h2 className="subtitle is-5">{edge.node.frontmatter.title}</h2>
                              <p>{edge.node.excerpt}</p>
                              </div>
                            </div>
                          )
                        }
                      )
                     }
                    </div>
                    )
            })}
        </div>
);


Related Query

More Query from same tag