diff --git a/steps/transform.ts b/steps/transform.ts index 1f53a52..31affe1 100644 --- a/steps/transform.ts +++ b/steps/transform.ts @@ -63,26 +63,34 @@ const convertDocuments = async (): Promise => { const extractLanguageElements = async (fileName, html): Promise => { const $ = cheerio.load(html); + $('meta[property^="og:"]').remove(); await Promise.all($('script') - .toArray() - .map(script => op.get(script, 'children.0.data', '')) - .filter(x => x) - .map(async (script, index) => { - const newFileName = md5(script); - try { - await fs.promises.writeFile(`${outDir}${newFileName}.js`, script.trim(), 'utf8'); - html = html.replace(script, `