Upgrade vue-cli to v4, change the way server params injection is made

and serve es6 modules

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2019-10-17 14:20:22 +02:00
parent 4b80b8616d
commit 6718dd8e69
10 changed files with 1314 additions and 840 deletions

View File

@@ -74,7 +74,7 @@ defmodule MobilizonWeb.PageView do
when page in ["actor.html", "event.html", "comment.html"] do
with {:ok, index_content} <- File.read(index_file_path()) do
tags = object |> Metadata.build_tags() |> MetadataUtils.stringify_tags()
index_content = String.replace(index_content, "<!--server-generated-meta-->", tags)
index_content = String.replace(index_content, "<meta name=server-injected-data>", tags)
{:safe, index_content}
end
end
@@ -82,7 +82,7 @@ defmodule MobilizonWeb.PageView do
def render("index.html", _assigns) do
with {:ok, index_content} <- File.read(index_file_path()) do
tags = Instance.build_tags() |> MetadataUtils.stringify_tags()
index_content = String.replace(index_content, "<!--server-generated-meta-->", tags)
index_content = String.replace(index_content, "<meta name=server-injected-data>", tags)
{:safe, index_content}
end
end