Compare commits

...

4 Commits

Author SHA1 Message Date
konnorrogers
1edf5a40e0 prettier 2025-09-10 10:25:05 -04:00
konnorrogers
0b8c3fa3d6 re-add support for 'unpublished: true' 2025-09-10 10:20:36 -04:00
konnorrogers
51a11f6785 prettier 2025-09-09 17:30:12 -04:00
konnorrogers
234301b0e6 add notes about skips 2025-09-09 17:14:08 -04:00
2 changed files with 11 additions and 0 deletions

View File

@@ -160,6 +160,15 @@ export default async function (eleventyConfig) {
// Use our own markdown instance
eleventyConfig.setLibrary('md', markdown);
// for files with `unpublished: true`, it will make sure they do not make it into the final build at all, but will be usable in development.
eleventyConfig.addPreprocessor('unpublished', '*', (data, content) => {
if (data.unpublished && process.env.ELEVENTY_RUN_MODE === 'build') {
return false;
}
return content;
});
// Add anchors to headings
eleventyConfig.addTransform('doc-transforms', function (content) {
let doc = HTMLParse(content, { blockTextElements: { code: true } });

View File

@@ -123,6 +123,7 @@ export async function build(options = {}) {
function generateReactWrappers() {
// Used by webawesome-app to make re-rendering not miserable with extra React file generation.
if (process.env.SKIP_SLOW_STEPS === 'true') {
spinner.info('Skipping React Wrapper generation.');
return Promise.resolve();
}
@@ -162,6 +163,7 @@ export async function build(options = {}) {
async function generateTypes() {
// Used by webawesome-app to make re-rendering not miserable with extra TS compilations.
if (process.env.SKIP_SLOW_STEPS === 'true') {
spinner.info('Skipping TypeScript compiler.');
return Promise.resolve();
}