-
Notifications
You must be signed in to change notification settings - Fork 26
Description
Hello..
Can you please advise how to compile custom javascript files? So far, no issue with compiling scss files.
Lando.yml:
build-sass:
description: Run sass compiler within node service
cmd: cd /app/web/themes/custom/mytheme/ && npx gulp compile
watch-sass:
service: node
description: Run sass compiler within node service
cmd: cd /app/web/themes/custom/mytheme && npx gulp watch
lando watch-sass:
gulpfile.js
/* gulpfile.js */
const uswds = require("@uswds/compile");
/**
- USWDS version
*/
uswds.settings.version = 3;
/**
- Path settings
- Set as many as you need
*/
uswds.paths.dist.css = './files/css';
uswds.paths.dist.theme = './sass'; //custom styles
uswds.paths.dist.js = './assets/js';
uswds.paths.src.js = './js'; //custom scripts
// const copy = {
// js() {
// log(
// colors.blue,
// Copy USWDS compiled JS: ${getSrcFrom("js")} → ${uswds.paths.src.js}
// );
// return src(${getSrcFrom("js")}/**/**.replace("//", "/")).pipe(
// dest(uswds.paths.dist.js)
// );
// },
// };
/**
- Exports
- Add as many as you need
*/
exports.init = uswds.init;
exports.compile = uswds.compile;
exports.watch = uswds.watch;
exports.copyJS = uswds.copyJS;
Any help is appreciated
Metadata
Metadata
Assignees
Labels
Type
Projects
Status