Reputation: 7599
I build my React app using Vite. This is my Vite config:
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
import commonjs from 'vite-plugin-commonjs';
import { APP_URL_BASENAME } from './src/constants/Config';
export default defineConfig(() => {
return {
plugins: [react(), commonjs()],
base: APP_URL_BASENAME ? APP_URL_BASENAME : '/blahblah/',
define: {
'process.env': process.env,
},
};
});
When I run my build I get my dist
folder.
When I copy this to my host, I get a message saying:
GET https://dev-apps.yada.com/project/assets/index-ASXLc9JY.js
net::ERR_HTTP2_PROTOCOL_ERROR 200 (OK)
The network tab seems to indicate that I'm loading the index.html
file, which in turn tries to load the index-ASXLc9JY.js
file, and the load of that asset is giving me that error.
The strange part is:
Upvotes: 0
Views: 19