-
-
Notifications
You must be signed in to change notification settings - Fork 6.2k
Fix various problems #35012
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix various problems #35012
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -18,6 +18,7 @@ | |
| white-space: nowrap; | ||
| overflow: hidden; | ||
| text-overflow: ellipsis; | ||
| cursor: default; | ||
| } | ||
|
|
||
| a.ui.label { | ||
|
|
||
| Original file line number | Diff line number | Diff line change | ||
|---|---|---|---|---|
|
|
@@ -9,5 +9,15 @@ import {onDomReady} from './utils/dom.ts'; | |||
| import 'htmx.org'; | ||||
|
|
||||
| onDomReady(async () => { | ||||
| await import(/* webpackChunkName: "index-domready" */'./index-domready.ts'); | ||||
| // when navigate before the import complete, there will be an error from webpack chunk loader: | ||||
| // JavaScript promise rejection: Loading chunk index-domready failed. | ||||
| try { | ||||
| await import(/* webpackChunkName: "index-domready" */'./index-domready.ts'); | ||||
| } catch (e) { | ||||
| if (e.name === 'ChunkLoadError') { | ||||
| console.error('Error loading index-domready:', e); | ||||
| } else { | ||||
| throw e; | ||||
| } | ||||
| } | ||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Side note: So we are waiting for
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The waiting time is almost the same as the old approach : But yes, we can start the import immediately, and only "init" in
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If there are no major benefits to this 2-chunk approach, maybe we should have all main JS in one chunk only. It's simpler design and whether the browser loads 1MB vs. 1.3MB makes no practical difference.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I also think we can merge them into one
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
If it is, which part makes the new index.js so large? #34960 (comment) Or the size difference is caused by different packing options? production vs dev?
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah yes likely you are seeing dev values. Dev JS is not minified: Line 108 in 091b3e6
|
||||
| }); | ||||


Uh oh!
There was an error while loading. Please reload this page.