Skip to content

Conversation

@hams7504
Copy link

No description provided.


useEffect(() => {
async function fetchData() {
console.log('test test testDENNIS');
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

might wanna remove this 🤔

};
export const fetchSiteInfo = async (siteId: number) => {
// Simulate an API call to fetch site information
const response = await fetch('http://localhost:3000/sites/' + siteId);
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you try using axios instead for endpoint calls?
Also, make sure to use ${import.meta.env.VITE_API_BASE_URL} instead of hardcoding the backend URL

setSelectedFilter={setSelectedFilter}
selectedName={selectedName}
setSelectedName={setSelectedName} />
<RenderFormControls
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for the formatting changes!


const allSites = await Promise.all(sitePromises);
setSites(allSites);
console.log(allSites);
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed console log, if we removed 177-8 how would we get the data

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just meant the console.log! i didn't realize my comment selected those lines as well

@denniwang denniwang merged commit 6567c09 into main Apr 16, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants