fix(build): don't purge used styles

Signed-off-by: SphericalKat <amolele@gmail.com>
This commit is contained in:
Amogh Lele 2021-10-07 09:06:08 +05:30
parent bca77b0ff6
commit ae8cee8ccf
No known key found for this signature in database
GPG Key ID: F0EA64BC1B44A7F3
3 changed files with 3 additions and 2 deletions

View File

@ -13,7 +13,7 @@ fs.copySync("static/", "../priv/static/");
console.log("[build.js] [info] Copying static files from static/"); console.log("[build.js] [info] Copying static files from static/");
if (!productionBuild) { if (!productionBuild) {
console.log("[build.js] [info] Starting to watching assets for changes"); console.log("[build.js] [info] Starting to watch assets for changes");
} else { } else {
console.log("[build.js] [info] Building assets in production mode"); console.log("[build.js] [info] Building assets in production mode");
} }

View File

@ -3,6 +3,7 @@ module.exports = {
"../lib/**/*.ex", "../lib/**/*.ex",
"../lib/**/*.leex", "../lib/**/*.leex",
"../lib/**/*.eex", "../lib/**/*.eex",
"../lib/**/*.heex",
"./js/**/*.js", "./js/**/*.js",
], ],
darkMode: false, // or 'media' or 'class' darkMode: false, // or 'media' or 'class'

View File

@ -9,7 +9,7 @@
<% end %> <% end %>
</div> </div>
<%= if @extension == "md" do%> <%= if @extension == "md" do%>
<div class="break-word px-6 py-4 h-full w-full markdown overflow-y-auto"><%= raw Earmark.as_html!(@paste.content, escape: true, gfm_tables: true) %></div> <div class="break-word px-6 py-4 h-full w-full markdown overflow-y-auto"><%= raw Earmark.as_html!(@paste.content, escape: true, gfm_tables: true) |> HtmlSanitizeEx.html5 %></div>
<% else %> <% else %>
<code class="break-word px-6 py-4 h-full w-full overflow-y-auto"><%= raw Ketbin.Utils.Syntax.highlight_text(@paste.content, @extension) |> HtmlSanitizeEx.html5 %></code> <code class="break-word px-6 py-4 h-full w-full overflow-y-auto"><%= raw Ketbin.Utils.Syntax.highlight_text(@paste.content, @extension) |> HtmlSanitizeEx.html5 %></code>
<% end %> <% end %>