mirror of
https://github.com/nasa/openmct.git
synced 2025-06-17 22:58:14 +00:00
roll back TOC generation
This commit is contained in:
@ -117,21 +117,6 @@ GLOBAL.window = GLOBAL.window || GLOBAL; // nomnoml expects window to be define
|
||||
};
|
||||
return transform;
|
||||
}
|
||||
|
||||
function strip() {
|
||||
var patternsToStrip = [
|
||||
"^<!--"],
|
||||
transform = new stream.Transform({ objectMode: true });
|
||||
transform._transform = function (chunk, encoding, done) {
|
||||
//If chunk does not match pattern, keep it, else discard (by not
|
||||
// pushing into stream)
|
||||
if (!chunk.trim().match(patternsToStrip.join("|"))){
|
||||
this.push(chunk);
|
||||
}
|
||||
done();
|
||||
};
|
||||
return transform;
|
||||
}
|
||||
|
||||
// Custom renderer for marked; converts relative links from md to html,
|
||||
// and makes headings linkable.
|
||||
@ -182,7 +167,6 @@ GLOBAL.window = GLOBAL.window || GLOBAL; // nomnoml expects window to be define
|
||||
fs.createReadStream(file, { encoding: 'utf8' })
|
||||
.pipe(split())
|
||||
.pipe(nomnomlifier(destPath, prefix))
|
||||
.pipe(strip())
|
||||
.pipe(gfmifier())
|
||||
.pipe(fs.createWriteStream(destination, {
|
||||
encoding: 'utf8'
|
||||
|
Reference in New Issue
Block a user