Closed aaronsajo closed 3 years ago
@aaronsajo Good Question. 🎉 It should be made for the whatever category is filtered, that is on load by default we are loading 4 categories. (National, World, Business and Sports) and therefore search should be done on them. if say, we have filtered only Sports and Business, then search only on Sports and Business.
@aaronsajo Ok, I mistook the question, but definitely the point mentioned above would be useful and the answer to your original question would be, on 25 news articles of whatever category is filtered on screen.
@MazahirHaroon :Thanks You.
@MazahirHaroon : I have some doubts about React Portal. Can I have call with you?
@aaronsajo Is it possible for you to share the query on a loom video? and if required after that we could get on a call later on.
@MazahirHaroon : Portal is used to render children into a DOM node that exists outside the DOM hierarchy of the parent component. In examples , Parent component will be sibling of root(id) div in index.html (like modal-root) and child will child of the root div i.e child of app.js. My doubt: Is this applicable only for root div and its siblings in index.html or Can it be used anywhere inside the app component like: Suppose there are 2 siblings inside the app.js and can portal be used to render child of 1st sibling in 2nd sibling?
Attaching Parent node in an example seen for better understanding.
@aaronsajo
Refer to this video: https://www.youtube.com/watch?v=HpHLa-5Wdys
Ref Docs: https://reactjs.org/docs/portals.html
Suppose there are 2 siblings inside the app.js and can portal be used to render child of 1st sibling in 2nd sibling?
For more clarity, we can discuss the same over a call.
@MazahirHaroon @JaganKaartik : While searching ,does the search should be made among the 5 displayed news of each category in landing page or among the 25 news of each category retrieved from the api call?