summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Andreas Benkard <code@mail.matthias.benkard.de>2020-01-23 10:27:36 +0100
committerMatthias Andreas Benkard <code@mail.matthias.benkard.de>2020-01-23 10:27:36 +0100
commit282c84aac7284ed8d0ee264936b3587373a80177 (patch)
tree6e1e5efb5e1b2041ec660dc7d15b09b8af334e6b
parent5e0b78376ff48fc098afcc395b23f90e59a2ea90 (diff)
Frontend: Put import map into its own file.
Change-Id: I0357d6961acedbae5b8ed8b65c45e7c8a5469178
-rw-r--r--src/main/resources/META-INF/resources/admin/index.html14
-rw-r--r--src/main/resources/META-INF/resources/importmap.json9
2 files changed, 10 insertions, 13 deletions
diff --git a/src/main/resources/META-INF/resources/admin/index.html b/src/main/resources/META-INF/resources/admin/index.html
index 6e91fd4..d91bbdd 100644
--- a/src/main/resources/META-INF/resources/admin/index.html
+++ b/src/main/resources/META-INF/resources/admin/index.html
@@ -6,19 +6,7 @@
<title>MulkCMS Admin</title>
<script defer src="/node_modules/es-module-shims/dist/es-module-shims.js"></script>
-
- <script type="importmap-shim">
- {
- "imports": {
- "loose-envify": "/node_modules/loose-envify/loose-envify.js",
- "js-tokens": "/node_modules/js-tokens/index.js",
- "symbol-observable": "/node_modules/symbol-observable/es/index.js",
- "redux": "/node_modules/redux/es/redux.mjs",
- "lit-html": "/node_modules/lit-html/lit-html.js"
- }
- }
- </script>
-
+ <script type="importmap-shim" src="/importmap.json"></script>
<script type="module-shim" src="/admin/admin.js"></script>
</head>
diff --git a/src/main/resources/META-INF/resources/importmap.json b/src/main/resources/META-INF/resources/importmap.json
new file mode 100644
index 0000000..42cae7b
--- /dev/null
+++ b/src/main/resources/META-INF/resources/importmap.json
@@ -0,0 +1,9 @@
+{
+ "imports": {
+ "loose-envify": "/node_modules/loose-envify/loose-envify.js",
+ "js-tokens": "/node_modules/js-tokens/index.js",
+ "symbol-observable": "/node_modules/symbol-observable/es/index.js",
+ "redux": "/node_modules/redux/es/redux.mjs",
+ "lit-html": "/node_modules/lit-html/lit-html.js"
+ }
+}