Skip to content

Commit 9aba1a9

Browse files
authored
Merge pull request #470 from QuantumFusion-network/khssnv/dev-portal-platform
ADR #14: Developer Portal Platform
2 parents 9b49756 + 74bc0c7 commit 9aba1a9

File tree

1 file changed

+237
-0
lines changed

1 file changed

+237
-0
lines changed
Lines changed: 237 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,237 @@
1+
# ADR_0014: Developer Portal Platform
2+
3+
## Date
4+
5+
Decision date: 2025-09-17
6+
Last status update: 2025-09-25
7+
8+
## Status
9+
10+
- [ ] Proposed
11+
- [x] Accepted
12+
- [ ] Deprecated
13+
- [ ] Superseded
14+
15+
### Implementation Status
16+
17+
- [ ] Planned
18+
- [x] In Development
19+
- [ ] Implemented
20+
- [ ] Verified
21+
- [ ] Discontinued
22+
23+
## People
24+
25+
### Author/Decision Owner
26+
27+
- Alisher Khassanov, [@khssnv](https://github.com/khssnv)
28+
- Denis Pisarev, [@TriplEight](https://github.com/TriplEight)
29+
30+
### Consulted
31+
32+
- Andreea Eftene [@statictype](https://github.com/statictype)
33+
- Alexander Lygin, [@alexlgn](https://github.com/AlexLgn)
34+
- Memechi Kekamoto, [@MemechiKekamoto](https://github.com/MemechiKekamoto)
35+
36+
### Informed
37+
38+
- [x] Alex Vyatkin, [@actinfer](https://github.com/actinfer)
39+
- [x] Sviatoslav Alekseev, [@zotho](https://github.com/zotho)
40+
41+
## Decision
42+
43+
We will use Starlight (Astro JS framework) for the QF Network Developer Portal.
44+
This portal will serve as the entry point for developers, providing educational materials and referencing additional documentation sources, e.g., rustdoc and mdBook-based API references for Rust projects.
45+
The Diataxis framework is recommended for organizing its content.
46+
47+
## Context
48+
49+
QF Network requires a comprehensive developer portal supporting multiple content types and audiences. The decision involves selecting tools and platforms that balance technical capabilities, maintenance overhead, and team expertise while delivering an excellent developer experience.
50+
51+
**Content Types:**
52+
53+
- Entry point and developer onboarding
54+
- Guides and tutorials for various skill levels
55+
- Live documentation by w3zard
56+
- Rust documentation:
57+
- Blockchain node internal documentation
58+
- Native Rust SDK for smart contracts public documentation
59+
60+
**Current Tech Stack:**
61+
62+
- Main website: Svelte
63+
- Other applications: React
64+
65+
### Decision Criteria
66+
67+
- **Developer Experience**: Search functionality, code snippets, navigation, and modern UX
68+
- **Technical Capabilities**: SSR support, SEO optimization, framework flexibility
69+
- **Team Alignment**: Compatibility with existing tech stack and skills
70+
- **Maintenance Overhead**: Long-term support and update requirements
71+
- **Documentation Architecture**: Support for Diataxis pattern and cross-linking
72+
- **Hiring and Skills**: Impact on recruitment and team development
73+
74+
## Options
75+
76+
1. Starlight/Astro-based Unified Platform (SELECTED)
77+
2. Docusaurus-based Platform
78+
3. SaaS (GitBook)
79+
4. Status Quo
80+
81+
## Consequences
82+
83+
### Option 1: Starlight/Astro-based Unified Platform (SELECTED)
84+
85+
Starlight built on Astro framework as the primary documentation platform, with rustdoc integration for Rust API documentation.
86+
87+
**Selected because:**
88+
89+
- Superior technical features (search, code snippets, SSR for islands)
90+
- SEO-friendly with server-side rendering capabilities
91+
- Framework-agnostic - can integrate existing React and Svelte components
92+
- Modern appeal for developer hiring and team satisfaction
93+
- Better maintenance characteristics than alternatives
94+
- Built-in support for versioning through extensions
95+
- Supports Diataxis documentation pattern effectively
96+
97+
**Selected despite:**
98+
99+
- Introduces new technology (Astro) to the team's stack
100+
- Learning curve for team members unfamiliar with Astro
101+
- Potential maintenance overhead from additional framework
102+
- Potential fragmentation concerns
103+
104+
**Risks and Mitigations:**
105+
106+
- **Risk**: Team skill gap with Astro framework
107+
- **Mitigation**: Astro uses familiar JavaScript/TypeScript concepts; documentation framework requires minimal ongoing development
108+
- **Risk**: Fragmented tooling and deployment complexity
109+
- **Mitigation**: Modern SSGs deploy similarly across hosting platforms; tooling alignment is consistent
110+
111+
**Failure Recovery:**
112+
Migration to Docusaurus or GitBook remains possible as content is primarily markdown-based.
113+
114+
### Option 2: Docusaurus-based Platform
115+
116+
React-based Docusaurus for documentation with separate rustdoc hosting.
117+
118+
**Rejected because:**
119+
120+
- React components not SEO-friendly without SSR
121+
- Less advanced search and code snippet capabilities
122+
- More limited modern documentation features
123+
- Not significantly better aligned with existing React usage
124+
125+
**Rejected despite:**
126+
127+
- Familiarity with React ecosystem
128+
- More standardized choice in React ecosystem
129+
- Potentially lower learning curve for team
130+
131+
### Option 3: SaaS (GitBook)
132+
133+
**Rejected because:**
134+
135+
- Less precise control of the website.
136+
137+
**Rejected despite:**
138+
139+
- Easier configuration.
140+
- Less maintenance overhead.
141+
- Doesn't bring new technology to the stack.
142+
143+
### Option 4: Status Quo
144+
145+
**Rejected because:**
146+
147+
- Fails to address developer portal requirements
148+
- Maintains poor developer onboarding experience
149+
- No unified content strategy
150+
151+
## Implementation Notes
152+
153+
- Deploy Starlight site to match existing infrastructure patterns
154+
- Follow Diataxis documentation framework for content organization (tutorials, how-to guides, technical reference, explanations)
155+
- Use starlight-versions plugin for documentation versioning
156+
- Integrate rustdoc output for Rust API documentation within Starlight navigation structure
157+
- Implement cross-linking strategy between Starlight content and rustdoc sections
158+
- Maintain consistency with main website branding and navigation patterns
159+
160+
## Confirmation
161+
162+
- [ ] Starlight deployment successfully hosts sample content
163+
- [ ] rustdoc integration maintains cross-linking functionality
164+
- [ ] Search functionality works across all content types
165+
- [ ] Successful integration of React/Svelte components from existing codebase
166+
- [ ] Version management working effectively for multiple documentation versions
167+
168+
## Advice
169+
170+
### General Architectural and Documentation Advice
171+
172+
- "I would exclude polkadot.com... I would generally start with docs.polkadot.com and wiki.polkadot.com." (Denis Pisarev, 2025-07-30)
173+
- "Paritytech.github.io is generally just rustdoc, and it needs to be merged into this similar domain or docs.polkadot.com regardless." (Denis Pisarev, 2025-07-30)
174+
- "Let's conduct separate studies of what tools web projects use, and then compare and draw some conclusions." (Denis Pisarev, 2025-07-30)
175+
- "I plan for like built-in documentation so there will be like question mark buttons and explanations everywhere... content will be published on documentation portal and... there will be a link to documentation." (Denis Pisarev, 2025-07-30)
176+
- "The central source of truth will move to... the developer portal." (Denis Pisarev, 2025-07-30)
177+
- "Have you considered diataxis? <https://diataxis.fr/application/> the most useful docs for me follow this pattern. it is quite common in the JavaScript world. I find it more meaningful than what Astar has." (Andreea Eftene, 2025-09-17)
178+
179+
### Option 1: Starlight/Astro Platform
180+
181+
**Technical Arguments Supporting Starlight:**
182+
183+
- "In a nutshell, I like Starlight because of its focus on user friendly technical documentation and modern approaches. The search is better, the code snippets are better, it is the only one that supports SSR for its islands" (Andreea Eftene, 2025-09-17)
184+
- "The content that comes from React in a Docusaurus setup will not be SEO friendly" - highlighting SEO advantages (Andreea Eftene, 2025-09-17)
185+
- "I'd move from Docusaurus to it [Starlight]." (Denis Pisarev, 2025-09-17)
186+
- "I've seen many Starlight example deployments with versioning." (Denis Pisarev, 2025-09-17)
187+
188+
### Technology Stack Concerns and Responses
189+
190+
**Concerns About Third Framework:**
191+
192+
- "I'm a little concerned about the third JavaScript framework in the company, we already have the website built using Svelte and React for everything else" (Alisher Khassanov, 2025-09-16)
193+
- "This means all the typical considerations apply: weaker skill concentration, reduced code reuse, fragmented tooling/infra, probably higher hiring overhead, increased maintenance cost" (Alisher Khassanov, 2025-09-17)
194+
- "What do you think makes Starlight more compelling for us than, say, Docusaurus, which is probably be the default choice for teams working primarily with React?" (Alisher Khassanov, 2025-09-17)
195+
196+
**Responses Addressing Technology Stack Concerns:**
197+
198+
- "Astro is framework-agnostic. You can use both Svelte and React components with it" - addressing code reuse concerns (Andreea Eftene, 2025-09-17)
199+
- "... working with Astro Starlight and React vs working with Docusaurus and React should not be that different in terms of skills needed" (Andreea Eftene, 2025-09-17)
200+
- "You can deploy any JavaScript framework to any hosting platform (Cloudflare, Vercel etc) with more or less the same code. The instructions to do so are spoon-fed on each tool's website. Tooling is 100% the same." (Andreea Eftene, 2025-09-17)
201+
- "It is expected from frontend devs to juggle multiple frameworks... also, frontend devs love modern stuff, so tech stack mentioning Astro Starlight is more appealing than Docusaurus" (Andreea Eftene, 2025-09-17)
202+
- "We have to maintain the project either way. I would argue that Astro is a more modern framework that makes maintenance easier." (Andreea Eftene, 2025-09-17)
203+
204+
### Option 3: Mixed Platform Approach
205+
206+
- "rustdoc is unavoidable. It's the only thing for Rust documentation... rustdoc kind of doesn't fit for it [MD documentation]." (Denis Pisarev, 2025-07-30)
207+
- "Making... the other documentation in MdBook or MK docs compatible in terms of linking or cross-linking between MdBook parts of portal and the rustdoc part of portal that's going to be tricky and effectively no one is doing it." (Denis Pisarev, 2025-07-30)
208+
- "Everything that supports a modern MD format is capable of having the links to the chapters, to the paragraphs, and that would be enough." (Denis Pisarev, 2025-07-30)
209+
210+
## Glossary
211+
212+
- **Astro**: Modern web framework focusing on content-driven websites with component flexibility
213+
- **Diataxis Framework**: Documentation framework organizing content into four types: tutorials, how-to guides, technical reference, and explanations
214+
- **Entry point**: Starting page for accessing developer portal content, integrated into main website
215+
- **Framework-agnostic**: Ability to work with or integrate components from multiple JavaScript frameworks (React, Svelte, etc.)
216+
- **GitHub Pages**: Website hosted directly from GitHub repository. Example: <https://paritytech.github.io/polkadot-sdk/>
217+
- **Islands Architecture**: Astro's approach to selectively hydrating interactive components
218+
- **SSR (Server-Side Rendering)**: Technique where web pages are rendered on the server before being sent to the client, improving SEO and initial load performance
219+
- **Starlight**: Documentation framework built on Astro, specifically designed for technical documentation sites
220+
- **Static Site Generator (SSG)**: Tool that generates static HTML pages from templates and content, enabling fast-loading websites
221+
- **rustdoc**: Official documentation generation tool for Rust projects, part of the standard Rust toolchain
222+
223+
## References
224+
225+
- [Starlight Documentation](https://starlight.astro.build/)
226+
- [Astro Framework Documentation](https://docs.astro.build/)
227+
- [Astro vs Docusaurus Migration Guide](https://docs.astro.build/en/guides/migrate-to-astro/from-docusaurus/)
228+
- [Starlight Versions Plugin](https://github.com/HiDeoo/starlight-versions)
229+
- [Starlight Search Example](https://starlight.astro.build/guides/site-search/)
230+
- [Astro React Integration](https://docs.astro.build/en/guides/integrations-guide/react/)
231+
- [Astro Svelte Integration](https://docs.astro.build/en/guides/integrations-guide/svelte/)
232+
- [Diataxis Documentation Framework](https://diataxis.fr/)
233+
- [Docusaurus Documentation](https://docusaurus.io/)
234+
- [MdBook for Rust Projects](https://rust-lang.github.io/mdBook/)
235+
- Polkadot documentation portals: <https://polkadot.com/> -> <https://polkadot.com/developers> -> <https://docs.polkadot.com/> -> <https://docs.polkadot.com/develop/>
236+
- [Modern Polkadot documentation portal built with rustdoc](https://paritytech.github.io/polkadot-sdk/)
237+
- [Build on Crust guide](https://wiki.crust.network/docs/en/build101)

0 commit comments

Comments
 (0)