NASA-PDS / portal-wp

New PDS Website driven by the PDS Web Modernization Working Group
Apache License 2.0
0 stars 0 forks source link

The codebase can't be run when using the "preview" command. #19

Closed anilnatha closed 1 month ago

anilnatha commented 1 month ago

💡 Description

When the command npm run preview is used, the portal code can't be accessed in a browser due to an error.

image

⚔️ Parent Epic / Related Tickets

No response

anilnatha commented 1 month ago

After researching this issue and trying a number of fixes, nothing worked.

In an attempt to better understand the issue I created a test package and test app which are configured very similar to our wds-react and portal-wp codebases. Incrementally I added functionality until I was able to replicate the issue which occurred when Material UI components were integrated into the package and app, and referenced in the app. Adding the material ui components to the package didn't not cause an error, only when those components are referenced in the app and run in preview mode.

The repos for these test codebases are test-react-package and test-react-app.

tloubrieu-jpl commented 1 month ago

@eddiesarevalo is going to try to fix the issue.

eddiesarevalo commented 1 month ago

@anilnatha Added a fix.

PR for wds-react: https://github.com/NASA-PDS/wds-react/pull/61 PR for portal-wp: https://github.com/NASA-PDS/portal-wp/pull/21

anilnatha commented 1 month ago

This fix has been merged to the develop branch, so I am closing this ticket.