mirror of
https://github.com/len0rd/personal-website.git
synced 2025-03-01 03:51:57 -05:00
remove garbage
This commit is contained in:
parent
8bbd4dbcf7
commit
b1196a34c9
12
prestart.js
12
prestart.js
|
@ -16,15 +16,6 @@ const showdown = require('showdown'),
|
||||||
|
|
||||||
//handles adding classes to specific
|
//handles adding classes to specific
|
||||||
//tag types automatically
|
//tag types automatically
|
||||||
const bindings = Object.keys(classMap)
|
|
||||||
.map(key => ({
|
|
||||||
|
|
||||||
|
|
||||||
type: 'output',
|
|
||||||
regex: new RegExp(`<${key}(.*?)>`, 'g'),
|
|
||||||
replace: `<${key} class="${classMap[key]}">`
|
|
||||||
}));
|
|
||||||
|
|
||||||
const addClass = {
|
const addClass = {
|
||||||
type: 'output',
|
type: 'output',
|
||||||
filter: text => {
|
filter: text => {
|
||||||
|
@ -47,8 +38,7 @@ const addClass = {
|
||||||
};
|
};
|
||||||
|
|
||||||
const converter = new showdown.Converter({
|
const converter = new showdown.Converter({
|
||||||
extensions: [addClass]//bindings]//,
|
extensions: [addClass]
|
||||||
// noHeaderId: false // important to add this, else regex match doesn't work
|
|
||||||
});
|
});
|
||||||
|
|
||||||
mkdirp(outputDir, (err) => {
|
mkdirp(outputDir, (err) => {
|
||||||
|
|
Loading…
Reference in a new issue