mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-17 15:33:12 +09:00
Move all web assets to shared cached space
Put all web assets including plugin assets under a shared static/ route in the web interface that's declared as immutable and cacheable for 1 year. This allows all JavaScript bundles to be loaded from disk instead of having to check with the web server each time and significantly speeds up the web interface load time. It also fixes the public path issue when using the --dev-plugin option behind a proxy. To prevent collisions and stale data all assets now include a hash in the filename. This means the entrypoint is now dynamic and specified in a manifest.json file created from the web build. For plugins this means the filename attribute needs to be removed from webpack.config.js.
This commit is contained in:
1 parent
2401fe25fa
commit
e32637503d
14 files changed
+90
-33
No files matched your search
@@ -51,7 +51,7 @@ export default function PluginViewPage() {
|
||||
style={{
|
||||
marginTop: "1em",
|
||||
}}
|
||||
message="Error loading web module"
|
||||
message={pluginMeta.web.error || "Error loading web module"}
|
||||
description={
|
||||
"The web interface was unable to load the webpack module for this plugin. This is "+
|
||||
"usually due to an incorrect or missing webpack build for the plugin. Due to the "+
|
||||
|
||||
Reference in new issue
Block a user