<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Prashant Vaghela</title>
    <description>The latest articles on Forem by Prashant Vaghela (@prashant_vaghela_91c78686).</description>
    <link>https://forem.com/prashant_vaghela_91c78686</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3659371%2F6a832177-2c55-48b6-a7b2-d96eb8d80374.png</url>
      <title>Forem: Prashant Vaghela</title>
      <link>https://forem.com/prashant_vaghela_91c78686</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/prashant_vaghela_91c78686"/>
    <language>en</language>
    <item>
      <title>Vite + Antd App works on Windows but Single Page crashes on Linux Production (Minified React Error #130)</title>
      <dc:creator>Prashant Vaghela</dc:creator>
      <pubDate>Sat, 13 Dec 2025 04:45:00 +0000</pubDate>
      <link>https://forem.com/prashant_vaghela_91c78686/vite-antd-app-works-on-windows-but-single-page-crashes-on-linux-production-minified-react-error-3l11</link>
      <guid>https://forem.com/prashant_vaghela_91c78686/vite-antd-app-works-on-windows-but-single-page-crashes-on-linux-production-minified-react-error-3l11</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fbgx4dpgni28vbpfz3je1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fbgx4dpgni28vbpfz3je1.png" alt=" " width="800" height="385"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I have a React application (Vite + Ant Design) deployed on Nginx (Linux). The application works perfectly in my local environment (Windows) and usually runs fine in production.&lt;/p&gt;

&lt;p&gt;The Issue: The entire application works correctly until I navigate to one specific route (MachinesDashboard).&lt;/p&gt;

&lt;p&gt;On Windows (Local &amp;amp; Prod build): The page loads perfectly.&lt;/p&gt;

&lt;p&gt;On Linux (Nginx Production): Clicking this specific route immediately crashes the page with a error boundary screen.&lt;/p&gt;

&lt;p&gt;The Error: The console logs:&lt;/p&gt;

&lt;p&gt;Minified React error #130: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: object.&lt;/p&gt;

&lt;p&gt;My Debugging So Far: I suspected an invalid import, so I added console.log statements inside the crashing component (MachinesDashboard) in the production build to inspect the imports.&lt;/p&gt;

&lt;p&gt;Code &amp;amp; Logs: Here are the imports in the crashing file:&lt;/p&gt;

&lt;p&gt;JavaScript&lt;/p&gt;

&lt;p&gt;import { Select, Badge, Button, Statistic, Row, Col, message, Modal } from 'antd';&lt;br&gt;
import {&lt;br&gt;
  ClockCircleOutlined,&lt;br&gt;
  WarningOutlined,&lt;br&gt;
  ArrowRightOutlined,&lt;br&gt;
  FullscreenOutlined,&lt;br&gt;
} from '@ant-design/icons';&lt;br&gt;
import EChart from '../../components/common/Echarts'; &lt;br&gt;
import DraftDetails from '../../components/common/DraftDetails';&lt;br&gt;
import CoreTable from '../../components/common/CoreTable/CoreTable';&lt;br&gt;
import Icon from '../../components/SvgIcon/Icon';&lt;br&gt;
What the Production Logs Show: I logged these components in the crashing environment:&lt;/p&gt;

&lt;p&gt;EChart: Function (Valid)&lt;/p&gt;

&lt;p&gt;DraftDetails: Function (Valid)&lt;/p&gt;

&lt;p&gt;CoreTable: Function (Valid)&lt;/p&gt;

&lt;p&gt;Icon: Function (Valid)&lt;/p&gt;

&lt;p&gt;ClockCircleOutlined: Object ({$$typeof: Symbol(react.forward_ref), ...}) (Valid React Ref)&lt;/p&gt;

&lt;p&gt;My Question: Since all my custom components and the Icons seem to be valid, why does this specific route crash only on Linux?&lt;/p&gt;

&lt;p&gt;Could this be related to:&lt;/p&gt;

&lt;p&gt;Ant Design Imports: Do destructured imports like import { Row, Col } from 'antd' sometimes resolve to an empty object/module in Linux production builds?&lt;/p&gt;

&lt;p&gt;File System Case Sensitivity: I have checked my file names (DraftDetails.tsx, ECharts.tsx) and they seem to match, but could a mismatched folder name cause an import to become an object without throwing a 404?&lt;/p&gt;

&lt;p&gt;Cyclic Dependencies: Could a circular dependency behave differently on Linux (due to file sorting) causing a component to be undefined/object at render time?&lt;/p&gt;

&lt;p&gt;Environment:&lt;/p&gt;

&lt;p&gt;React 18 / Vite 4&lt;/p&gt;

&lt;p&gt;Host: Linux Ubuntu + Nginx&lt;/p&gt;

&lt;p&gt;Build: vite build&lt;/p&gt;

</description>
      <category>devops</category>
      <category>help</category>
      <category>linux</category>
      <category>react</category>
    </item>
  </channel>
</rss>
