Create proper shim for xss library - second attempt

Create proper shim for xss library - second attempt

diff --git a/app/assets/javascripts/discourse-shims.js b/app/assets/javascripts/discourse-shims.js
index d6ccfbe..384fb92 100644
--- a/app/assets/javascripts/discourse-shims.js
+++ b/app/assets/javascripts/discourse-shims.js
@@ -25,6 +25,10 @@ define("bootbox", ["exports"], function (__exports__) {
   __exports__.default = window.bootbox;
 });
 
+define("xss", ["exports"], function (__exports__) {
+  __exports__.default = window.filterXSS;
+});
+
 define("mousetrap", ["exports"], function (__exports__) {
   __exports__.default = window.Mousetrap;
 });
diff --git a/app/assets/javascripts/pretty-text-bundle.js b/app/assets/javascripts/pretty-text-bundle.js
index 62dd6c1..2a3862f 100644
--- a/app/assets/javascripts/pretty-text-bundle.js
+++ b/app/assets/javascripts/pretty-text-bundle.js
@@ -6,7 +6,6 @@
 //= require ./pretty-text/addon/emoji
 //= require ./pretty-text/addon/engines/discourse-markdown-it
 //= require xss.min
-//= require ./pretty-text/addon/xss
 //= require ./pretty-text/addon/white-lister
 //= require ./pretty-text/addon/sanitizer
 //= require ./pretty-text/addon/oneboxer
diff --git a/app/assets/javascripts/pretty-text/addon/sanitizer.js b/app/assets/javascripts/pretty-text/addon/sanitizer.js
index 26eef20..aaf8005 100644
--- a/app/assets/javascripts/pretty-text/addon/sanitizer.js
+++ b/app/assets/javascripts/pretty-text/addon/sanitizer.js
@@ -1,4 +1,4 @@
-import xss from "pretty-text/xss";
+import xss from "xss";
 
 function attr(name, value) {
   if (value) {
diff --git a/app/assets/javascripts/pretty-text/addon/xss.js b/app/assets/javascripts/pretty-text/addon/xss.js
deleted file mode 100644
index d2189b1..0000000
--- a/app/assets/javascripts/pretty-text/addon/xss.js
+++ /dev/null
@@ -1,2 +0,0 @@
-// Shim for xss.js library
-export default window.filterXSS;

GitHub sha: 8c384ae6