Apply suggestion to src/commands/mdn.ts
parent
cd86c3f7ee
commit
d71a159054
|
@ -33,10 +33,8 @@ export default class MDN extends Command {
|
||||||
// Do not touch to the next block of code. Don't even look at it. your brain could stop working
|
// Do not touch to the next block of code. Don't even look at it. your brain could stop working
|
||||||
data.Summary = data.Summary.replace(/<code><strong>/g, '<strong><code>');
|
data.Summary = data.Summary.replace(/<code><strong>/g, '<strong><code>');
|
||||||
data.Summary = data.Summary.replace(/<\/strong><\/code>/g, '</code></strong>');
|
data.Summary = data.Summary.replace(/<\/strong><\/code>/g, '</code></strong>');
|
||||||
data.Summary = data.Summary.replace(/<code>/g, '`');
|
data.Summary = data.Summary.replace(/<code>|<\/code>/g, '`');
|
||||||
data.Summary = data.Summary.replace(/<\/code>/g, '`');
|
data.Summary = data.Summary.replace(`/<strong>|<\/strong>/g, '**');`
|
||||||
data.Summary = data.Summary.replace(/<strong>/g, '**');
|
|
||||||
data.Summary = data.Summary.replace(/<\/strong>/g, '**');
|
|
||||||
const url = data.Summary.match(/<a href=.*>/);
|
const url = data.Summary.match(/<a href=.*>/);
|
||||||
if (url !== null) {
|
if (url !== null) {
|
||||||
url[0] = url[0].replace('<a href="', '');
|
url[0] = url[0].replace('<a href="', '');
|
||||||
|
|
Loading…
Reference in New Issue