Ghost/ghost/admin/lib/koenig-editor/addon/helpers/clean-basic-html.js
Kevin Ansfield d412e624d5 Use extracted @tryghost/kg-clean-basic-html package
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
2019-05-02 17:14:00 +01:00

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);