about summary refs log tree commit diff
path: root/app/javascript/packs
diff options
context:
space:
mode:
Diffstat (limited to 'app/javascript/packs')
-rw-r--r--app/javascript/packs/application.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/app/javascript/packs/application.js b/app/javascript/packs/application.js
index 91240aecf..0851f69b6 100644
--- a/app/javascript/packs/application.js
+++ b/app/javascript/packs/application.js
@@ -4,8 +4,10 @@ import { start } from '../mastodon/common';
 
 start();
 
-loadPolyfills().then(() => {
-  require('../mastodon/main').default();
+loadPolyfills().then(async () => {
+  const { default: main } = import('mastodon/main');
+
+  return main();
 }).catch(e => {
   console.error(e);
 });