Skip to content

Commit 51fe6f6

Browse files
Merge branch 'master' into feat/sistent-dynamic-pagination
2 parents f1f480d + 20fd5c7 commit 51fe6f6

File tree

9 files changed

+340
-513
lines changed

9 files changed

+340
-513
lines changed

Makefile

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,14 @@ setup:
2121
# "make site" - The default lightweight build keeps the dev server fast by skipping heavy collections.
2222
## Run a partial build of layer5.io on your local machine.
2323
site:
24-
@echo "🏗️ Building lightweight site version (core profile excludes Members, Integrations, Blog, News, Events, and Resources collections)..."
24+
@echo "🏗️ Building lightweight site version ($(or $(LITE_BUILD_PROFILE),core) profile)..."
2525
@echo " Use LITE_BUILD_PROFILE=content make site to include content collections while still skipping the heaviest routes."
26-
@npm run develop:lite
26+
@npx cross-env BUILD_FULL_SITE=false LITE_BUILD_PROFILE=$(or $(LITE_BUILD_PROFILE),core) BLOG_YEAR=$(or $(BLOG_YEAR),) GATSBY_CPU_COUNT=4 SHARP_CONCURRENCY=4 UV_THREADPOOL_SIZE=4 NODE_OPTIONS=--max-old-space-size=8192 env-cmd -f .env.development gatsby develop
27+
28+
## Run blog-only dev server (2026 posts only, much faster builds).
29+
site-blog:
30+
@echo "🏗️ Building lightweight site version with blog collection only..."
31+
LITE_BUILD_PROFILE=blog BLOG_YEAR=2026 $(MAKE) site
2732

2833
# "make site-full" forces the dev server to include every collection.
2934
## Run a full build of layer5.io on your local machine.

gatsby-node.js

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1110,6 +1110,20 @@ exports.createSchemaCustomization = ({ actions }) => {
11101110
const typeDefs = `
11111111
type Mdx implements Node {
11121112
frontmatter: Frontmatter
1113+
fields: MdxFields
1114+
}
1115+
1116+
type MdxFields {
1117+
collection: String
1118+
slug: String
1119+
dateForSort: Date @dateformat
1120+
learnpath: String
1121+
course: String
1122+
section: String
1123+
chapter: String
1124+
pageType: String
1125+
permalink: String
1126+
componentName: String
11131127
}
11141128
11151129
type FrontmatterComponent {
@@ -1129,6 +1143,12 @@ exports.createSchemaCustomization = ({ actions }) => {
11291143
url: String
11301144
}
11311145
1146+
type FrontmatterContents {
1147+
id: Int
1148+
link: String
1149+
text: String
1150+
}
1151+
11321152
type Frontmatter {
11331153
title: String
11341154
subtitle: String
@@ -1195,6 +1215,30 @@ exports.createSchemaCustomization = ({ actions }) => {
11951215
thumbnail_svg: File @fileByRelativePath
11961216
darkthumbnail_svg: File @fileByRelativePath
11971217
meshesYouLearn: [FrontmatterMeshesYouLearn]
1218+
program: String
1219+
programSlug: String
1220+
docType: String
1221+
apply_by: String
1222+
redirectLink: String
1223+
register: Boolean
1224+
salary: String
1225+
start_date: String
1226+
duration: String
1227+
courses: Int
1228+
speakers: [String]
1229+
darkimgsrc: File @fileByRelativePath
1230+
lightimgsrc: File @fileByRelativePath
1231+
cover: File @fileByRelativePath
1232+
themeColor: String
1233+
disabled: String
1234+
contents: [FrontmatterContents]
1235+
component: String
1236+
chapterTitle: String
1237+
courseTitle: String
1238+
lectures: Int
1239+
videos: Int
1240+
order: Int
1241+
toc: [String]
11981242
}
11991243
`;
12001244
createTypes(typeDefs);

0 commit comments

Comments
 (0)