All Questions
119
questions
0
votes
0
answers
23
views
React Vite Error on Production Build: "jsxs" is not exported by "node_modules/react/jsx-runtime.js
I am using React + Javascript + Vite for the project. I installed the required packages for the project , Also i install one package from local npm installation eg
npm install source_folder
The ...
0
votes
0
answers
29
views
Bundle single static .mjs file without any modules using Vite
I am building a vanilla TS SPA that is using Vite as the build tool. For my main app, I have a index.html with a script tag pointing to the entry point .ts file, and that all works great.
However, I ...
0
votes
1
answer
37
views
Is it possible to make a contentEditable div have a fixed height in React.js?
I have this contentEditable div and I need it to have a fixed size/capacity. The div should not keep making new lines if it reaches the capacity and the user shouldn't be able to keep typing in the ...
1
vote
2
answers
81k
views
Is it true to have the index-xxxx,js/css files are necessary to force the cache to clear?
So I've been told by the project manager of this project I'm volunteering for that keeping names for files like index-xxxx.js will help to force the cache to clear if we use them in like the root ...
-2
votes
1
answer
67
views
Accessing environment variables in index.html file
I am trying to access some environment variables inside of the index.html file. Are the environment variables even accessible at the time the index.html builds? I have tried something along the lines ...
0
votes
1
answer
60
views
How to use SVG from file with multiple SVGs by ID selector with ::before
Core problem:
I am using a third party library where I can only set text (no HTML or JS) as a label, but I want to add an icon before the text. The icon is part of an svg file that contains multiple ...
0
votes
1
answer
71
views
How to dynamically color an imported SVG icon in Svelte without CSS filters?
I am running into trouble trying to achieve a simple task: with an icon imported into a Svelte component using Vite's asset import, how can I change the color of the icon?
<script>
// This ...
0
votes
0
answers
28
views
Vite Vanilla Js build is showing blank page in live server
I installed the latest Vite template using Vite Official Docs.
I am using the Vanilla JS,
The problem is that when I create a build by using npm run build and open it with a live server.
It will show ...
1
vote
2
answers
785
views
How do I solve the error "Failed to resolve import "src/lib/utils" from ... Does the file exist?"
I am a beginner in react and am trying to follow this tutorial (https://www.youtube.com/watch?v=_W3R2VwRyF4) on youtube. I am trying to test out the button component I am building, but I keep getting ...
0
votes
0
answers
102
views
Vite Production Build: CSS/JS Not Loading
I'm having trouble with my HTML, CSS, and JavaScript project using Vite. I'm building a Recipe Website with the MealDBAPI. The project works locally, but when I build it for production using npm run ...
0
votes
0
answers
50
views
How to redirect to another website with tauri + vite + typescript?
I'm making an app with tauri + vite + typescript, but when I want to redirect to another page from my script, it doesn't allow me to redirect the webview to another html. How can I redirect the ...
0
votes
1
answer
59
views
Why my multipage React app dont show my pages?
It`s my first React project and i want to make a multi page app for my BackEnd API, but none of my pages appear on the Screen
App.jsx
import React from 'react';
import { HashRouter as Router, Routes, ...
2
votes
1
answer
56
views
React Element with HTML Parameters Not Rendering
On a page, I have a element embedded in HTML:
{dataTable}
Which is initialised as:
const [dataTable, setDataTable] = useState(<p>Data Table Loading...</p>);
And updated in a useEffect ...
0
votes
1
answer
150
views
How to cross-load assets from separate site built with Vite as you would with Webpack in an HTML file?
I recently upgraded one of my projects from Vue-cli/Vue 2 over to Vue 3 and Vite for deployment. The app was deployed to an external server and works perfectly fine. However, the switch from vue-cli ...
0
votes
1
answer
24
views
React: Issue with Skipping Style Update in ShowOn Function
I'm encountering a problem with updating styles in my React application. I have a function ShowOn that should change the width of the TaskTab component and then update the state isActiveShow. However, ...