HeadstartWP
-Next.js Framework for WordPress
+Next.js Framework for Headless WordPress
Documentation
+Developer Guide
If you are unsure how to do something with the framework, this is where you should start. diff --git a/docs/src/pages/index.module.css b/docs/src/pages/index.module.css index 16cf451f8..854907858 100644 --- a/docs/src/pages/index.module.css +++ b/docs/src/pages/index.module.css @@ -7,11 +7,61 @@ padding: 6rem 0; text-align: center; position: relative; - background-color: var(--c-10up-secondary); + /* No overflow:hidden here - the search dropdown must be able to + extend past the hero. The lattice stays contained because the + ::after box is inset:0 with border-radius:inherit. */ + /* Mirrors the main site's hero: soft lavender wash with the purple + radial from the top right, and the lattice graphic ghosted on the + right (CSS background keeps it inert - no click capture, no + gradient-id collisions). */ + background: + radial-gradient(153.4% 328.78% at 88.61% -33.98%, rgba(163, 107, 163, 0.24) 0%, rgba(163, 107, 163, 0) 53.12%), + #faf8fb; border-radius: 2rem; margin-inline: 1rem; } +.heroBanner::after { + content: ""; + position: absolute; + inset: 0; + border-radius: inherit; + background: url("../../static/img/hero-lattice.svg") no-repeat right -8rem center; + background-size: auto 200%; + opacity: 0.5; + pointer-events: none; +} + +.heroBanner > * { + position: relative; + z-index: 1; +} + +/* The oversized lattice reads great wide, but scales down busy — step the + crop and strength down with the viewport. */ +@media (max-width: 1200px) { + .heroBanner::after { + background-position: right -5rem center; + background-size: auto 160%; + opacity: 0.4; + } +} + +@media (max-width: 996px) { + .heroBanner::after { + background-position: right -4rem center; + background-size: auto 130%; + opacity: 0.25; + } +} + +@media (max-width: 600px) { + .heroBanner::after { + background-size: auto 110%; + opacity: 0.18; + } +} + .heroBanner p { font-size: 1.25rem; } diff --git a/docs/src/pages/philosophy.md b/docs/src/pages/philosophy.md index c06fd74c6..026656b86 100644 --- a/docs/src/pages/philosophy.md +++ b/docs/src/pages/philosophy.md @@ -1,16 +1,16 @@ # Framework Principles -These are the guiding principles for 10up's Headless Framework. +These are the guiding principles for HeadstartWP, Fueled's framework for headless WordPress. ## Solid Foundation -We aren't trying to reinvent the wheel nor do we want to spend a massive amount of resources building a new foundation for our framework. Therefore we decided to pick an existing and solid foundation to power 10up's Headless Framework: [Next.js](https://nextjs.org/). +We aren't trying to reinvent the wheel nor do we want to spend a massive amount of resources building a new foundation for our framework. Therefore we decided to pick an existing and solid foundation to power HeadstartWP: [Next.js](https://nextjs.org/). Next.js is by far the most used Full-Stack React Framework and we believe using Next.js will give us a solid foundation for our framework and let us focus on what matters: solving headless WordPress sites. ## Reduce the complexity of building headless sites -The 10up headless framework aims at making creating headless sites as easy as creating traditional WordPress sites. We want to reduce the complexity that developers need to face when building headless WordPress sites from scratch. +HeadstartWP aims at making creating headless sites as easy as creating traditional WordPress sites. We want to reduce the complexity that developers need to face when building headless WordPress sites from scratch. We aim to let engineers focus on the important aspects of the site instead of spending time figuring out how to "wire up" the Next.js application with WordPress. @@ -20,7 +20,7 @@ We want to boost creativity and let engineers explore new ways of building and s ## Low cost of maintenance -The 10up headless framework is a thin layer built on top of a solid foundation. It focuses on interacting with WordPress. At the end of the day, it's a Next.js application. +HeadstartWP is a thin layer built on top of a solid foundation. It focuses on interacting with WordPress. At the end of the day, it's a Next.js application. This means the maintenance cost is low as the lowest-level and most complex parts are provided by Next.js which is maintained by Vercel and have been driving a lot of innovations alongside partners like Google. @@ -30,7 +30,7 @@ We also aim at maintaining a simple stack. ### REST API over WPGraphQL -The 10up's Headless Framework at the moment does not work with WPGraphQL. +HeadstartWP at the moment does not work with WPGraphQL. GraphQL is great and when used on the right project adds tons of value in the long run. However, for most headless sites, there isn’t much value added by GraphQL. The additional complexity and engineering time required by adopting GraphQL/WPGraphQL isn’t worth the cost most of the time (caching, persisted queries, cache-bursting, etc). diff --git a/docs/src/theme/Footer/index.js b/docs/src/theme/Footer/index.js index 03619e62c..d317c84c9 100644 --- a/docs/src/theme/Footer/index.js +++ b/docs/src/theme/Footer/index.js @@ -4,90 +4,91 @@ import React from 'react'; import Footer from '@theme-original/Footer'; import useBaseUrl from '@docusaurus/useBaseUrl'; +/** + * Bottom band mirrors the footer on headstartwp.fueled.com: greyish-blue + * ground, "Finely crafted by Fueled (formerly 10up)" with a links row, + * centered white Fueled lockup, GitHub + LinkedIn on the right. + */ export default function FooterWrapper(props) { + const year = new Date().getFullYear(); + return ( <> -
- - Careers at 10up - -
- Open source, MIT licensed.
-
- Copyright © 2025
-
+[](http://10up.com/contact/)
diff --git a/docs/docusaurus.config.js b/docs/docusaurus.config.js
index 9896e10ed..bdc3e3757 100644
--- a/docs/docusaurus.config.js
+++ b/docs/docusaurus.config.js
@@ -6,11 +6,13 @@ import { themes as prismThemes } from 'prism-react-renderer';
/** @type {import('@docusaurus/types').Config} */
const config = {
- title: 'HeadstartWP Docs - Next.js Framework for WordPress',
+ title: 'HeadstartWP Docs - Next.js Framework for Headless WordPress',
tagline: '',
- url: 'https://headstartwp.10up.com',
+ url: 'https://headstartwp.fueled.com',
baseUrl: '/docs',
- onBrokenLinks: 'throw',
+ // Links into the generated /api section are unavoidably broken when
+ // SKIP_TYPEDOC skips generation — downgrade so local builds still pass.
+ onBrokenLinks: process.env.SKIP_TYPEDOC ? 'warn' : 'throw',
onBrokenMarkdownLinks: 'warn',
favicon: 'img/favicon.ico',
organizationName: '10up', // Usually your GitHub org/user name.
@@ -32,9 +34,19 @@ const config = {
({
docs: false,
blog: false,
- googleTagManager: {
- containerId: 'GTM-TKCGKK2',
- },
+ // Same Google tag as the main site (Site Kit on
+ // headstartwp.fueled.com) — one GA4 property covers the full
+ // site→docs journey. Replaces the legacy 10up GTM container.
+ // Production-only: in dev the gtag script never loads, so the
+ // plugin's route-change handler would throw on every navigation.
+ ...(process.env.NODE_ENV === 'production'
+ ? {
+ gtag: {
+ trackingID: 'GT-WRDG786',
+ anonymizeIP: true,
+ },
+ }
+ : {}),
theme: {
customCss: './src/css/custom.css',
},
@@ -43,21 +55,29 @@ const config = {
],
plugins: [
- [
- 'docusaurus-plugin-typedoc',
- {
- name: 'HeadstartWP',
- out: './docs',
- entryPoints: ['../packages/core', '../packages/next'],
- entryPointStrategy: 'packages',
- packageOptions: {
- entryPoints: ['src/docs-entry-point.ts'],
- },
- categorizeByGroup: false,
- excludeInternal: true,
- readme: 'none',
- },
- ],
+ // SKIP_TYPEDOC=1 skips API-reference generation for faster local
+ // theme/content work (it needs the monorepo packages installed and
+ // built). CI always runs it. Local builds still get working search,
+ // minus API-reference entries (see the search plugin config below).
+ ...(process.env.SKIP_TYPEDOC
+ ? []
+ : [
+ [
+ 'docusaurus-plugin-typedoc',
+ {
+ name: 'HeadstartWP',
+ out: './docs',
+ entryPoints: ['../packages/core', '../packages/next'],
+ entryPointStrategy: 'packages',
+ packageOptions: {
+ entryPoints: ['src/docs-entry-point.ts'],
+ },
+ categorizeByGroup: false,
+ excludeInternal: true,
+ readme: 'none',
+ },
+ ],
+ ]),
[
'@docusaurus/plugin-content-docs',
{
@@ -97,8 +117,11 @@ const config = {
'@easyops-cn/docusaurus-search-local',
{
indexDocs: true,
- docsRouteBasePath: ['learn', 'api'],
- docsDir: ['documentation', 'docs'],
+ // Search must only reference contexts that emit an index: with
+ // SKIP_TYPEDOC there is no /api content, and a missing context
+ // index leaves the search loader hanging forever.
+ docsRouteBasePath: process.env.SKIP_TYPEDOC ? ['learn'] : ['learn', 'api'],
+ docsDir: process.env.SKIP_TYPEDOC ? ['documentation'] : ['documentation', 'docs'],
hashed: true,
},
],
@@ -121,7 +144,7 @@ const config = {
type: 'doc',
docId: 'index',
position: 'right',
- label: 'Docs',
+ label: 'Developer Guide',
},
{
type: 'doc',
@@ -135,6 +158,12 @@ const config = {
position: 'left',
dropdownActiveClassDisabled: true,
},
+ {
+ href: 'https://headstartwp.fueled.com/',
+ label: 'About HeadstartWP',
+ position: 'right',
+ className: 'navbar-site-cta',
+ },
],
},
announcementBar: {
@@ -149,24 +178,53 @@ const config = {
style: 'light',
links: [
{
- title: 'Docs',
+ title: 'Docs & Community',
items: [
{
- label: 'Documentation',
+ label: 'Developer Guide',
to: '/learn',
},
{
label: 'API Reference',
to: '/api',
},
+ {
+ label: 'GitHub Discussions',
+ href: 'https://github.com/10up/headstartwp/discussions/',
+ },
],
},
{
- title: 'Community',
+ title: 'HeadstartWP',
items: [
{
- label: 'GitHub Discussions',
- href: 'https://github.com/10up/headstartwp/discussions/',
+ label: 'Main site',
+ href: 'https://headstartwp.fueled.com/',
+ },
+ {
+ label: 'News & Updates',
+ href: 'https://headstartwp.fueled.com/news/',
+ },
+ {
+ label: 'Privacy Policy',
+ href: 'https://headstartwp.fueled.com/privacy-policy/',
+ },
+ ],
+ },
+ {
+ title: 'Fueled (formerly 10up)',
+ items: [
+ {
+ label: 'WordPress',
+ href: 'https://fueled.com/wordpress/?utm_source=referral&utm_medium=Website%20Referral&utm_campaign=headstartwp.fueled.com&utm_content=docs-footer',
+ },
+ {
+ label: 'Hire us',
+ href: 'https://fueled.com/contact/?utm_source=referral&utm_medium=Website%20Referral&utm_campaign=headstartwp.fueled.com&utm_content=docs-footer-hire',
+ },
+ {
+ label: 'Careers',
+ href: 'https://fueled.com/careers/?utm_source=referral&utm_medium=Website%20Referral&utm_campaign=headstartwp.fueled.com&utm_content=docs-footer-careers',
},
],
},
diff --git a/docs/src/css/custom.css b/docs/src/css/custom.css
index f0a1b18a9..347ee3135 100644
--- a/docs/src/css/custom.css
+++ b/docs/src/css/custom.css
@@ -4,7 +4,7 @@
* work well for content-centric websites.
*/
-@import url("https://fonts.googleapis.com/css2?family=Cabin:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500;1,600;1,700&display=swap");
+@import url("https://fonts.googleapis.com/css2?family=IBM+Plex+Sans+Condensed:wght@600;700&family=IBM+Plex+Sans:ital,wght@0,400;0,500;0,600;0,700;1,400&display=swap");
@font-face {
font-family: "Virgil";
diff --git a/docs/src/css/global-footer.css b/docs/src/css/global-footer.css
index fe2f081b8..9712db87e 100644
--- a/docs/src/css/global-footer.css
+++ b/docs/src/css/global-footer.css
@@ -3,97 +3,108 @@
border-top: 2px solid var(--ifm-color-secondary-lightest);
}
-.footer-about {
- background-color: var(--ifm-color-secondary-lightest);
- padding: 3rem var(--ifm-spacing-horizontal);
-}
-
-.footer-about-inner {
- margin: 0 auto;
- max-width: var(--wide-width);
+/* --- Bottom band: mirrors the headstartwp.fueled.com site footer --- */
+
+.footer-fueled {
+ background-color: #323F60;
+ color: #fff;
+ font-size: 0.8rem;
+ font-weight: 300;
+ padding: 3.5rem var(--ifm-spacing-horizontal);
text-align: center;
}
-.cta-careers {
- vertical-align: top;
+.footer-fueled a {
+ color: #fff;
+ text-decoration: underline;
}
-.license {
- margin-top: 20px;
+.footer-fueled a:hover {
+ color: #ddd;
}
-.license p {
+.footer-fueled p {
margin: 0;
}
-.license .copyright {
- margin-right: 4px;
+.footer-fueled .footer-links {
+ list-style: none;
+ display: flex;
+ flex-wrap: wrap;
+ justify-content: center;
+ gap: 4px 18px;
+ margin: 6px 0 0;
+ padding: 0;
}
-@media (min-width: 900px) {
- .cta-careers {
- display: inline-block;
- vertical-align: top;
- text-align: left;
- width: 48%;
- }
-
- .license {
- display: inline-block;
- margin-left: 2%;
- text-align: right;
- width: 48%;
- margin-top: 0;
- }
+.footer-fueled .footer-links li {
+ opacity: 0.75;
}
-.cta-careers .button {
- margin-top: .5em;
- background-color: var(--ifm-color-primary);
- text-decoration: none;
+.footer-fueled .footer-links li:hover {
+ opacity: 1;
}
-.cta-careers .button:hover {
- background-color: var(--ifm-color-primary-dark);
+.footer-fueled .footer-links a {
+ color: inherit;
}
-
-.footer-10up {
- padding: 3rem var(--ifm-spacing-horizontal);
+.footer-fueled .logo img {
+ width: 170px;
+ height: auto;
+ display: block;
+ margin: 30px auto;
}
-.footer-10up .wrap {
- margin: 0 auto;
- max-width: var(--wide-width);
- text-align: center;
+.footer-fueled .social ul {
+ list-style: none;
+ display: flex;
+ justify-content: center;
+ gap: 5px;
+ margin: 0;
+ padding: 0;
}
-.footer-10up .social-media svg {
- width: 25px;
- margin-right: 15px;
+.footer-fueled .social svg {
+ width: 24px;
+ display: block;
}
-.footer-10up .social-media path {
- fill: var(--ifm-color-gray-600);
+.footer-fueled .social path {
+ fill: #fff;
}
-.footer-10up .social-media svg:hover path {
- fill: var(--ifm-color-black);
+.footer-fueled .social a:hover path {
+ fill: #ddd;
}
-.footer-10up p {
- margin: 20px 0;
+.footer-fueled .sr-only {
+ position: absolute;
+ width: 1px;
+ height: 1px;
+ overflow: hidden;
+ clip: rect(1px, 1px, 1px, 1px);
}
@media (min-width: 900px) {
- .footer-10up .wrap {
- display: flex;
- text-align: left;
+ .footer-fueled .wrap {
+ display: grid;
+ grid-template-columns: 1fr 170px 1fr;
align-items: center;
- justify-content: space-between;
+ max-width: var(--wide-width);
+ margin: 0 auto;
+ text-align: left;
+ }
+
+ .footer-fueled .footer-links {
+ justify-content: flex-start;
+ }
+
+ .footer-fueled .logo img {
+ margin: 0 auto;
}
- .footer-10up p {
- margin: 0;
+ .footer-fueled .social ul {
+ justify-content: flex-end;
}
-}
\ No newline at end of file
+}
diff --git a/docs/src/css/global-header.css b/docs/src/css/global-header.css
index 24019fc91..5be752860 100644
--- a/docs/src/css/global-header.css
+++ b/docs/src/css/global-header.css
@@ -8,4 +8,18 @@
html:not(.docs-wrapper) .navbar {
box-shadow: none;
-}
\ No newline at end of file
+}
+/* CTA back to the main site (mirrors the site header's Get Started chip). */
+.navbar-site-cta {
+ background: #1C1F37;
+ color: #fff !important;
+ border-radius: 2px;
+ padding: 8px 16px;
+ margin-left: 8px;
+ font-weight: 600;
+ text-decoration: none;
+}
+
+.navbar-site-cta:hover {
+ background: var(--ifm-color-primary);
+}
diff --git a/docs/src/css/variables.css b/docs/src/css/variables.css
index 0c35aaafa..36dc3d32f 100644
--- a/docs/src/css/variables.css
+++ b/docs/src/css/variables.css
@@ -8,23 +8,26 @@
--g2-color-slate: #40464d;
--g2-color-black: #1e1e1e;
+ /* HeadstartWP site palette (headstartwp.fueled.com): teal links on
+ navy ink, light-blue accents. */
--ifm-footer-link-color: var(--ifm-color-black);
- --ifm-color-primary: #df2b26;
- --ifm-color-primary-dark: #B5130E;
- --ifm-color-primary-darker: #213dd3;
- --ifm-color-primary-darkest: #8A0400;
- --ifm-color-primary-light: #FE4641;
- --ifm-color-primary-lighter: #FF6662;
- --ifm-color-primary-lightest: #FF918E;
+ --ifm-color-primary: #33647E;
+ --ifm-color-primary-dark: #2B5468;
+ --ifm-color-primary-darker: #284E61;
+ --ifm-color-primary-darkest: #1C1F37;
+ --ifm-color-primary-light: #3B7492;
+ --ifm-color-primary-lighter: #3F7C9C;
+ --ifm-color-primary-lightest: #4BA0C4;
--ifm-footer-background-color: #fff;
--ifm-link-decoration: underline;
--ifm-link-hover-color: var(--ifm-color-primary-dark);
--ifm-code-font-size: 1rem;
--ifm-container-width-xl: 130ch;
--ifm-container-width: 90ch;
- --ifm-font-family-base: -apple-system, BlinkMacSystemFont, "Segoe UI",
- Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
- --ifm-heading-font-family: var(--ifm-font-family-base);
+ --ifm-font-family-base: "IBM Plex Sans", -apple-system, BlinkMacSystemFont,
+ "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji",
+ "Segoe UI Emoji";
+ --ifm-heading-font-family: "IBM Plex Sans Condensed", var(--ifm-font-family-base);
--ifm-h1-font-size: 2.625rem;
--ifm-h2-font-size: 2rem;
--ifm-heading-font-weight: var(--ifm-font-weight-semibold);
@@ -32,9 +35,6 @@
--ifm-leading-desktop: 1.5;
--ifm-menu-color-background-active: white;
--ifm-navbar-height: 4.375rem;
- --c-10up-secondary: #E3FAF8;
- --c-10up-secondary-dark: #7ED5D4;
-
--wide-width: min(calc(100vw - 2.5rem), calc(var(--ifm-container-width-xl) + 300px));
--docusaurus-highlighted-code-line-bg: #e0e0e0;
diff --git a/docs/src/pages/index.js b/docs/src/pages/index.js
index 96c306cf8..7b3c0c5af 100644
--- a/docs/src/pages/index.js
+++ b/docs/src/pages/index.js
@@ -18,7 +18,7 @@ export default function Home() {