Skip to content

Commit

Permalink
fix: index.html no longer shows code beyond examples
Browse files Browse the repository at this point in the history
  • Loading branch information
mauriciopoppe committed Dec 19, 2023
1 parent c69fe55 commit fb4e938
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
/site/js/*function-plot.js
/site/js/*function-plot.js.map
/dist
/site/partials/examples.html
/site/partials/recipes.html
Expand Down
3 changes: 3 additions & 0 deletions site/js/site.js
Original file line number Diff line number Diff line change
Expand Up @@ -1080,6 +1080,9 @@ function onSiteDependenciesLoaded() {
}
]
})

// Important to leave the space before this line!
// It's because the script site.cjs parses this file to create the examples
}

$('#recipes').load('partials/recipes.html')
Expand Down
4 changes: 2 additions & 2 deletions site/partials/examples.html
Original file line number Diff line number Diff line change
Expand Up @@ -786,11 +786,11 @@
}
]
})
})
}

$('#recipes').load('partials/recipes.html')
$('#examples').load('partials/examples.html', function () {
$(document).trigger('markupLoaded')
onSiteDependenciesLoaded()
$('pre code').each(function (i, block) {
hljs.highlightBlock(block)
})
Expand Down

0 comments on commit fb4e938

Please sign in to comment.