mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-22 10:21:36 +03:00
d412e624d5
no issue - `cleanBasicHtml` has been extracted to an external package so that it can be used inside the extracted `@tryghost/kg-parser-plugins` package server-side
14 lines
340 B
JavaScript
14 lines
340 B
JavaScript
import cleanBasicHtml from '@tryghost/kg-clean-basic-html';
|
|
import {helper} from '@ember/component/helper';
|
|
import {isArray} from '@ember/array';
|
|
|
|
export function cleanBasicHtmlHelper(html = '') {
|
|
if (isArray(html)) {
|
|
html = html[0] || '';
|
|
}
|
|
|
|
return cleanBasicHtml(html);
|
|
}
|
|
|
|
export default helper(cleanBasicHtmlHelper);
|