Skip to content

Commit d0df43f

Browse files
committed
squash! do not include edit-on-github link in all.html
1 parent 3620da2 commit d0df43f

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

tools/doc/allhtml.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,8 @@ let all = toc.replace(/index\.html/g, 'all.html')
5252
.replace('<a href="all.html" name="toc">', '<a href="index.html" name="toc">')
5353
.replace('index.json', 'all.json')
5454
.replace('api-section-index', 'api-section-all')
55-
.replace('data-id="index"', 'data-id="all"');
55+
.replace('data-id="index"', 'data-id="all"')
56+
.replace(/<li class="edit-on-github">.*?<\/li>/, '');
5657

5758
// Clean up the title.
5859
all = all.replace(/<title>.*?\| /, '<title>');

tools/doc/html.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -381,5 +381,5 @@ function altDocs(filename, docCreated) {
381381
}
382382

383383
function editOnGitHub(filename) {
384-
return `<li><a href="https://github.com/nodejs/node/edit/master/doc/api/${filename}.md"><img src="assets/github_icon.svg" alt="" class="github_icon">Edit on GitHub</a></li>`;
384+
return `<li class="edit-on-github"><a href="https://github.com/nodejs/node/edit/master/doc/api/${filename}.md"><img src="assets/github_icon.svg" alt="" class="github_icon">Edit on GitHub</a></li>`;
385385
}

0 commit comments

Comments
 (0)