Fix missing highlightJS stylesheets

This commit renames the hilightjs stylesheet to include the ".min.css"
file suffix. Without that, highlightJS cannot load the custom
stylesheets.

Fixes gh-63
This commit is contained in:
Brian Clozel 2020-11-02 15:19:40 +01:00
parent 90bcada337
commit ba5f6b6a06
7 changed files with 14 additions and 3 deletions

View File

@ -1,4 +1,5 @@
const { src, dest, series, parallel, watch } = require('gulp'),
del = require('del'),
gulpSass = require('gulp-sass'),
asciidoctor = require('@asciidoctor/gulp-asciidoctor'),
gulpConnect = require('gulp-connect');
@ -14,6 +15,11 @@ const paths = {
* Building the theme
*/
// Cleans the build folder for the dev lifecycle
function clean(cb) {
del([paths.dist + '**'], cb());
}
// Compile SASS files to build/dist/css/
function sass() {
return src(paths.sass)
@ -71,6 +77,11 @@ function watchFiles(cb) {
cb();
}
// cleans the build folder for the dev lifecycle
function cleanDev(cb) {
del([paths.web + '**'], cb());
}
// Serve sample document and reload for changes
function connect(cb) {
gulpConnect.server({
@ -80,7 +91,7 @@ function connect(cb) {
cb();
}
const build = series(sass, copyResource);
const build = series(clean, sass, copyResource);
const update = series(build, copyDist, render);
exports.default = build;
exports.dev = series(update, parallel(connect, watchFiles));
exports.dev = series(cleanDev, update, parallel(connect, watchFiles));

View File

@ -4,9 +4,9 @@
"version": "0.1.1",
"repository": "https://github.com/spring-io/spring-doc-resources",
"license": "Apache-2.0",
"dependencies": {},
"devDependencies": {
"@asciidoctor/gulp-asciidoctor": "^2.2.5",
"del": "^6.0.0",
"gulp": "^4.0.2",
"gulp-connect": "^5.7.0",
"gulp-sass": "^4.1.0",