inveniosoftware / react-invenio-app-ils

Single Page App built with React for InvenioILS.
https://react-invenio-app-ils.readthedocs.io
MIT License
5 stars 19 forks source link

routes: Render browser tab title based on literature title #599

Open sakshamarora1 opened 6 months ago

sakshamarora1 commented 6 months ago

:heart: Thank you for your contribution!

Description

Note: This is just an example PR on how the tab title rendering would look code wise, I have listed down some pain points in this approach would be very happy to get some feedback -

  1. All the components that would require a browser title would need to have an extra renderTabTitle prop
  2. If the function is kept on the top level, when going to another component without a title, the previous title gets retained instead of just showing CERN Library Catalogue again as it should, fix is it set the document.title = to the components.