Skip to main content
Filter by
Sorted by
Tagged with
-3 votes
1 answer
60 views

I am using Vite to build react application. And I have a js file with data (it is just a word dictionary). The file is big, its size is 28MB. Now it is imported and use in code directly. So built js ...
Vight's user avatar
  • 31
1 vote
0 answers
131 views

I’m building a Chrome extension using React 18 and Vite 5, trying to implement code splitting for optimization. Despite excluding background scripts from splitting, I’m getting chunk loading errors. ...
Amol Soans's user avatar
0 votes
1 answer
213 views

In an "offline-first" app (which optimistically updates local state and gracefully handles errors by rolling back local state changes, for example), some features may still require internet ...
Audiopolis's user avatar
2 votes
4 answers
335 views

I'm learning Angular 18 while I already know React. I have a "pretty big" HTML file, which I would like to split. Let's take this pseudo and minified example: <ul> <li>Hello<...
ncasteln's user avatar
  • 342
1 vote
1 answer
299 views

I have just started learning Next.js and shadcn, but I am confused about how to split the code in the form component because my code has already reached 4000 lines. How can I split it to make it ...
Heru hoeruman's user avatar
-1 votes
1 answer
154 views

I want to do is I want to import React-Native dynamic path. example: import Demo from `./screens/${path}`; I found one method using lazy, but it also only working when initialize const variable like ...
kavindu's user avatar
  • 46
5 votes
2 answers
10k views

I have built a small application in Vue/TypeScript and with Vite and i am trying to build the files using vite build but this is chunking the files. The file is to be placed on other peoples website ...
Bryan88's user avatar
  • 447
-1 votes
1 answer
53 views

I have a react app that has >10 pages and imports a number of npm modules. import ReactDOM from "react-dom/client"; import { BrowserRouter, Routes, Route } from "react-router-dom&...
Oam Psy's user avatar
  • 8,663
1 vote
0 answers
2k views

I'm working on an embeddable widget for websites where clients embed the widget into their website using a script tag in the following format: <script src="https://embed.app.com/USER_ID"&...
Shaya Ulman's user avatar
  • 1,711
2 votes
1 answer
524 views

I'm trying to implement Code Splitting in a React Native app. Currently I managed to load multiple bundles in Android both in packager mode and in production mode. However, on iOS I'm facing the ...
Dor Ben Baruch's user avatar
1 vote
1 answer
1k views

I'm using Vue + Vite for my web app, and I use code-splitting in my router file for most of the routes, for example:  { path: "settings", name: "settings", component: () => ...
Perfect-Plant-4131's user avatar
0 votes
0 answers
577 views

Technology used: React Typescript Webpack (Essentially an ejected create-react-app as we plan to move away from CRA) Lazy loading at each route (react-router) We've been diagnosing a large main bundle ...
Jon Chabot's user avatar
1 vote
1 answer
2k views

I have a project: link. The project has router and lazy-components for every page. Short example router-component: export const RoutersComponent = () => { return ( <HashRouter basename={'/...
Roma N's user avatar
  • 320
2 votes
0 answers
788 views

Requirement: To prefetch the remote modules(module federated) during browser idle time in react. I've tried webpack magic comment webpackPrefetch: true but that did not work with module federation. I ...
macro's user avatar
  • 51
2 votes
2 answers
1k views

Backstory: I'm working on a codebase which is primarily Python with Jinja templates because the site is mainly static. However, for interactive components we're using Preact to pre-render the ...
FreddieMixell's user avatar
1 vote
1 answer
1k views

I have this code as a part of a Column having many children making it as long as 400 lines. Is it a good practice to split widgets like these into separate files? What is the recommended number of ...
Kartik's user avatar
  • 309
0 votes
2 answers
72 views

I'm working on a sheet that can be extracted from a system and all the data is in one cell so i need to split them and it is basic for all cells except for resutls. as you can see test results should ...
Qlowls's user avatar
  • 1
3 votes
0 answers
150 views

For explaining this issue. I have created a sample project. I am using purescript. I am doing a dynamic import and webpack is generating 2 bundles. If I comment the dynamic import and use a static ...
Avinash Verma's user avatar
2 votes
0 answers
30 views

I am currently using createAsyncThunk to create async middlewares for a React-Redux app I am working on in the following manner: import axios from "axios"; import ApiUrls from "../...
anas1149's user avatar
1 vote
0 answers
391 views

This is a topic that's been discussed a lot through github issues and by now I've noticed two main opinions: It's not possible or it should not be done at all. The argument for both sides is that ...
Koy's user avatar
  • 628
1 vote
2 answers
1k views

Lately I've been deep diving more about JS modules, Webpack, the difference between ES modules and CommonJS, and I came across the dynamic import topic. I was curious on how Webpack converts the ...
hskris's user avatar
  • 399
2 votes
0 answers
313 views

I have a single .js file containing multiple exports. It looks like this: // some-functions.js export function plusOne(value){ return value + 1 } export function minusOne(value){ return ...
Nathaniel's user avatar
  • 462
1 vote
1 answer
446 views

I am trying to import components from a published npm package dynamically using react-loadable. The import is successful with components located in the src/ folder. However any components that I try ...
Jacques's user avatar
  • 11
1 vote
0 answers
951 views

Im trying to lazy load routes but no matter what I do, I only have one main chunk. Here is the route code. import React, { Suspense, lazy } from "react"; import { HomePage, ProductsPage, ...
zeshan ahmad's user avatar
3 votes
1 answer
7k views

I'm looking into using Next.js for it's hybrid SSG/SSR features. Why are JS chunks being packed into simple pages that should require ZERO JavaScript? The build command outputs: Route (pages) ...
quiltedbread's user avatar

1
2 3 4 5
10