Move all files to javascript folder and remove coffeescript folder
This commit is contained in:
7
src/main/javascript/helpers/handlebars.js
Normal file
7
src/main/javascript/helpers/handlebars.js
Normal file
@@ -0,0 +1,7 @@
|
||||
'use strict';
|
||||
|
||||
Handlebars.registerHelper('sanitize', function(html) {
|
||||
// Strip the script tags from the html, and return it as a Handlebars.SafeString
|
||||
html = html.replace(/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi, '');
|
||||
return new Handlebars.SafeString(html);
|
||||
});
|
||||
Reference in New Issue
Block a user