Module not found

I’m trying to upload my frontend. But i’m being caught with these “Module not found” logs

I’ve been going through all the threads for this issue but I dont see any casing issues, pathing issues or error logs on my local machine. I’ve made changes to all my folder and files names by capitalizing them. The only way i see it possibly working is the folder name and file names were different but that doesn’t seem like the best way to go around this issue.

Any sort of guidance would be greatly appreicated

Github: GitHub - bpun1p/MERN-weather-app
Branch: prod

Render error logs

Render Build and Deploy:

Branch - prod
Root Directory - ./client
Build Command - npm run build
Publish Directory - build

App.js imports:

import React, { useState } from ‘react’;
import ‘./App.css’;
import ‘./components/Utils/Tooltip/Tooltip.css’
import Dashboard from ‘./components/Dasboard/Dashboard’;
import Nav from ‘./components/Navigation/Navigation’;
import Profile from ‘./components/Profile/Profile’;
import Library from ‘./components/Library/Library’;
import Access from ‘./components/Access/Access’;
import { BrowserRouter, Routes, Route } from ‘react-router-dom’;

Hi,

Render uses Linux which has a case-sensitive filesystem.

The error in your screenshot shows:

Module not found: Error: Can't resolve './components/Profile/Profile' in '/opt/render/project/src/client/src'

With components/Profile/Profile being the key part.

However, the profile folder in your repo has a lower-case p, whereas the code calling it uses and uppercase P. These would need to match.

Alan

1 Like

Thank you very much for answering my question, didnt realized my github wasn’t changing the casing when pushing my changes.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.