@knowcode/doc-builder 1.9.29 → 1.9.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (197) hide show
  1. package/assets/js/main.js +7 -0
  2. package/lib/core-builder.js +18 -1
  3. package/package.json +12 -2
  4. package/.claude/settings.local.json +0 -56
  5. package/CACHE-BUSTING-GUIDE.md +0 -82
  6. package/CLAUDE.md +0 -86
  7. package/CONTRIBUTING.md +0 -148
  8. package/GITHUB_SETUP.md +0 -203
  9. package/RELEASE-NOTES-1.7.5.md +0 -64
  10. package/Screenshot 2025-07-22 at 19.51.21.png +0 -0
  11. package/Screenshot 2025-07-26 at 17.06.49.png +0 -0
  12. package/add-user-clive.sql +0 -35
  13. package/add-user-lindsay-fixed.sql +0 -85
  14. package/add-user-lindsay.sql +0 -68
  15. package/add-user-pmorgan.sql +0 -35
  16. package/add-user-robbie.sql +0 -35
  17. package/add-wru-users.sql +0 -105
  18. package/debug-login.sql +0 -30
  19. package/doc-builder.config.js +0 -126
  20. package/doc-builder.config.js.backup.1753793768283 +0 -47
  21. package/doc-builder.config.js.backup.1753803964423 +0 -114
  22. package/doc-builder.config.js.backup.1753945707032 +0 -115
  23. package/doc-builder.config.js.backup.1754059241330 +0 -115
  24. package/doc-builder.config.js.backup.1754119567787 +0 -123
  25. package/doc-builder.config.js.backup.1754120048862 +0 -124
  26. package/doc-builder.config.js.backup.1754120529913 +0 -124
  27. package/doc-builder.config.js.backup.1754218469785 +0 -124
  28. package/doc-builder.config.js.backup.1754384764054 +0 -124
  29. package/doc-builder.config.js.backup.1754567425847 +0 -124
  30. package/doc-builder.config.js.backup.1754568137859 +0 -126
  31. package/doc-builder.config.js.backup.1754569388252 +0 -126
  32. package/doc-builder.config.js.backup.1754576694123 +0 -126
  33. package/doc-builder.config.js.backup.1755031374829 +0 -126
  34. package/doc-builder.config.js.backup.1755034500990 +0 -126
  35. package/grant-access.sql +0 -15
  36. package/html/11.png +0 -0
  37. package/html/404.html +0 -115
  38. package/html/README.html +0 -522
  39. package/html/Screenshot 2025-08-12 at 21.35.07.png +0 -0
  40. package/html/about-doc-builder.html +0 -491
  41. package/html/auth.js +0 -157
  42. package/html/claude-workflow-guide.html +0 -525
  43. package/html/css/notion-style.css +0 -2502
  44. package/html/documentation-index.html +0 -471
  45. package/html/guides/authentication-default-change.html +0 -370
  46. package/html/guides/authentication-guide.html +0 -509
  47. package/html/guides/cache-control-anti-pattern.html +0 -361
  48. package/html/guides/claude-workflow-guide.html +0 -1074
  49. package/html/guides/configuration-guide.html +0 -472
  50. package/html/guides/document-standards.html +0 -518
  51. package/html/guides/documentation-standards.html +0 -694
  52. package/html/guides/html-embedding-guide.html +0 -461
  53. package/html/guides/image-modal-guide.html +0 -515
  54. package/html/guides/next-steps-walkthrough.html +0 -638
  55. package/html/guides/phosphor-icons-guide.html +0 -584
  56. package/html/guides/private-directory-authentication-troubleshooting.html +0 -555
  57. package/html/guides/private-directory-authentication.html +0 -541
  58. package/html/guides/public-site-deployment.html +0 -431
  59. package/html/guides/search-engine-verification-guide.html +0 -542
  60. package/html/guides/seo-guide.html +0 -661
  61. package/html/guides/seo-optimization-guide.html +0 -887
  62. package/html/guides/supabase-auth-implementation-plan.html +0 -543
  63. package/html/guides/supabase-auth-integration-plan.html +0 -671
  64. package/html/guides/supabase-auth-setup-guide.html +0 -498
  65. package/html/guides/supabase-authentication-complete-guide.html +0 -866
  66. package/html/guides/troubleshooting-guide.html +0 -633
  67. package/html/guides/vercel-deployment-auth-setup.html +0 -337
  68. package/html/guides/windows-setup-guide.html +0 -859
  69. package/html/image-modal-test.html +0 -318
  70. package/html/index.html +0 -522
  71. package/html/js/auth.js +0 -157
  72. package/html/js/main.js +0 -1747
  73. package/html/launch/README.html +0 -297
  74. package/html/launch/bubble-plugin-specification.html +0 -933
  75. package/html/launch/go-to-market-strategy.html +0 -663
  76. package/html/launch/launch-announcements.html +0 -593
  77. package/html/login.html +0 -102
  78. package/html/logout.html +0 -18
  79. package/html/private/cache-control-anti-pattern.html +0 -429
  80. package/html/private/launch/README.html +0 -371
  81. package/html/private/launch/auth-cleanup-summary.html +0 -361
  82. package/html/private/launch/bubble-plugin-specification.html +0 -1007
  83. package/html/private/launch/go-to-market-strategy.html +0 -737
  84. package/html/private/launch/launch-announcements.html +0 -667
  85. package/html/private/launch/vercel-deployment-auth-setup.html +0 -417
  86. package/html/private/next-steps-walkthrough.html +0 -679
  87. package/html/private/supabase-auth-implementation-completed.html +0 -454
  88. package/html/private/supabase-auth-implementation-plan.html +0 -594
  89. package/html/private/supabase-auth-integration-plan.html +0 -704
  90. package/html/private/supabase-auth-setup-guide.html +0 -555
  91. package/html/private/test-private-doc.html +0 -302
  92. package/html/private/user-management-tooling.html +0 -601
  93. package/html/prompts/Screenshot 2025-08-02 at 08.49.55.png +0 -0
  94. package/html/prompts/beautiful-documentation-design.html +0 -784
  95. package/html/prompts/markdown-document-standards.html +0 -422
  96. package/html/prompts/project-rename-strategy-sasha-publish.html +0 -530
  97. package/html/robots.txt +0 -9
  98. package/html/sitemap.xml +0 -357
  99. package/html/test-questions/how-does-it-work%3F.html +0 -294
  100. package/html/test-questions/step-1%3A%20getting-started.html +0 -289
  101. package/html/test-questions/what-is-the-purpose.html +0 -293
  102. package/html/test-status.html +0 -281
  103. package/html/vercel-cli-setup-guide.html +0 -495
  104. package/html/vercel-first-time-setup-guide.html +0 -454
  105. package/html/vercel.json +0 -29
  106. package/html-static/11.png +0 -0
  107. package/html-static/404.html +0 -115
  108. package/html-static/README.html +0 -599
  109. package/html-static/Screenshot 2025-08-12 at 21.35.07.png +0 -0
  110. package/html-static/about-doc-builder.html +0 -568
  111. package/html-static/css/notion-style.css +0 -2502
  112. package/html-static/documentation-index.html +0 -548
  113. package/html-static/guides/authentication-default-change.html +0 -447
  114. package/html-static/guides/authentication-guide.html +0 -586
  115. package/html-static/guides/claude-workflow-guide.html +0 -1151
  116. package/html-static/guides/configuration-guide.html +0 -549
  117. package/html-static/guides/documentation-standards.html +0 -771
  118. package/html-static/guides/html-embedding-guide.html +0 -538
  119. package/html-static/guides/image-modal-guide.html +0 -592
  120. package/html-static/guides/phosphor-icons-guide.html +0 -661
  121. package/html-static/guides/private-directory-authentication-troubleshooting.html +0 -632
  122. package/html-static/guides/private-directory-authentication.html +0 -618
  123. package/html-static/guides/public-site-deployment.html +0 -508
  124. package/html-static/guides/search-engine-verification-guide.html +0 -619
  125. package/html-static/guides/seo-guide.html +0 -738
  126. package/html-static/guides/seo-optimization-guide.html +0 -964
  127. package/html-static/guides/supabase-authentication-complete-guide.html +0 -943
  128. package/html-static/guides/troubleshooting-guide.html +0 -710
  129. package/html-static/guides/windows-setup-guide.html +0 -936
  130. package/html-static/image-modal-test.html +0 -395
  131. package/html-static/index.html +0 -599
  132. package/html-static/js/main.js +0 -1747
  133. package/html-static/prompts/Screenshot 2025-08-02 at 08.49.55.png +0 -0
  134. package/html-static/prompts/beautiful-documentation-design.html +0 -861
  135. package/html-static/prompts/markdown-document-standards.html +0 -499
  136. package/html-static/prompts/project-rename-strategy-sasha-publish.html +0 -607
  137. package/html-static/robots.txt +0 -5
  138. package/html-static/sitemap.xml +0 -195
  139. package/html-static/test-questions/how-does-it-work%3F.html +0 -371
  140. package/html-static/test-questions/step-1%3A%20getting-started.html +0 -366
  141. package/html-static/test-questions/what-is-the-purpose.html +0 -370
  142. package/html-static/vercel-cli-setup-guide.html +0 -572
  143. package/html-static/vercel-first-time-setup-guide.html +0 -531
  144. package/manage-users.sql +0 -191
  145. package/migrate-to-domain-auth.sql +0 -47
  146. package/package/CACHE-BUSTING-GUIDE.md +0 -82
  147. package/package/CHANGELOG.md +0 -902
  148. package/package/README.md +0 -248
  149. package/package/assets/css/notion-style.css +0 -2211
  150. package/package/assets/js/auth.js +0 -67
  151. package/package/assets/js/main.js +0 -1565
  152. package/package/cli.js +0 -764
  153. package/package/index.js +0 -38
  154. package/package/knowcode-doc-builder-1.3.15.tgz +0 -0
  155. package/package/lib/builder.js +0 -32
  156. package/package/lib/config.js +0 -278
  157. package/package/lib/core-builder.js +0 -957
  158. package/package/lib/deploy.js +0 -497
  159. package/package/lib/dev-server.js +0 -96
  160. package/package/package.json +0 -34
  161. package/package/scripts/npx-runner.js +0 -27
  162. package/package/scripts/setup.js +0 -56
  163. package/package/test-cache-bust.sh +0 -43
  164. package/public-config.js +0 -22
  165. package/public-html/404.html +0 -115
  166. package/public-html/README.html +0 -149
  167. package/public-html/css/notion-style.css +0 -2036
  168. package/public-html/index.html +0 -149
  169. package/public-html/js/auth.js +0 -67
  170. package/public-html/js/main.js +0 -1485
  171. package/quick-test-commands.md +0 -40
  172. package/recordings/Screenshot 2025-07-24 at 18.22.01.png +0 -0
  173. package/recordings/mh-ls-22jul.txt +0 -2305
  174. package/screenshot.png +0 -0
  175. package/scripts/Screenshot 2025-07-23 at 15.39.41.png +0 -0
  176. package/setup-database-v2.sql +0 -53
  177. package/setup-database.sql +0 -41
  178. package/test-auth-config.js +0 -17
  179. package/test-cache-bust.sh +0 -43
  180. package/test-docs/README.md +0 -39
  181. package/test-html/404.html +0 -115
  182. package/test-html/README.html +0 -172
  183. package/test-html/auth.js +0 -97
  184. package/test-html/css/notion-style.css +0 -2036
  185. package/test-html/index.html +0 -172
  186. package/test-html/js/auth.js +0 -97
  187. package/test-html/js/main.js +0 -1485
  188. package/test-html/login.html +0 -102
  189. package/test-html/logout.html +0 -18
  190. package/update-domain.sql +0 -9
  191. package/user-access-view.sql +0 -49
  192. package/user-management/README.md +0 -301
  193. package/user-management/add-users.sh +0 -776
  194. package/user-management/create-user.js +0 -65
  195. package/user-management/users.txt +0 -15
  196. package/view-all-users.sql +0 -40
  197. package/wru-auth-config.js +0 -17
package/html/auth.js DELETED
@@ -1,157 +0,0 @@
1
-
2
- /**
3
- * Supabase Authentication for Documentation Site
4
- * Generated by @knowcode/doc-builder
5
- */
6
-
7
- (function() {
8
- 'use strict';
9
-
10
- // Skip auth check on login and logout pages
11
- const currentPage = window.location.pathname;
12
- if (currentPage === '/login.html' || currentPage === '/logout.html' ||
13
- currentPage.includes('login') || currentPage.includes('logout')) {
14
- return;
15
- }
16
-
17
- // Initialize Supabase client
18
- const { createClient } = supabase;
19
- const supabaseClient = createClient('https://xcihhnfcitjrwbynxmka.supabase.co', 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InhjaWhobmZjaXRqcndieW54bWthIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NTM0Mzc2MzcsImV4cCI6MjA2OTAxMzYzN30.zvWp3JFIR8fBIiwuFF5gqOR_Kxb42baZS5fsBz60XOY', {
20
- auth: {
21
- persistSession: true,
22
- autoRefreshToken: true,
23
- detectSessionInUrl: true
24
- }
25
- });
26
-
27
- // Check authentication and site access
28
- async function checkAuth() {
29
- try {
30
- // Check authentication mode
31
- const isGlobalAuthEnabled = false;
32
- const isPrivateDirectoryAuthEnabled = true;
33
-
34
- // Check if current page is in private directory
35
- const currentPath = window.location.pathname;
36
- const isPrivatePage = currentPath.includes('/private/');
37
-
38
- // Get current user session
39
- const { data: { user }, error: userError } = await supabaseClient.auth.getUser();
40
-
41
- if (userError || !user) {
42
- // Redirect if global auth is enabled OR if we're on a private page with private auth enabled
43
- if (isGlobalAuthEnabled || (isPrivateDirectoryAuthEnabled && isPrivatePage)) {
44
- redirectToLogin();
45
- } else {
46
- // Public page (no global auth and either no private auth or not on private page)
47
- document.body.classList.add('authenticated'); // Use same class to show body
48
- updateAuthButton(false);
49
- }
50
- return;
51
- }
52
-
53
- // Check if user has access to this site (using domain)
54
- const { data: access, error: accessError } = await supabaseClient
55
- .from('docbuilder_access')
56
- .select('*')
57
- .eq('user_id', user.id)
58
- .eq('domain', window.location.host)
59
- .single();
60
-
61
- if (accessError || !access) {
62
- if (isGlobalAuthEnabled || (isPrivateDirectoryAuthEnabled && isPrivatePage)) {
63
- showAccessDenied();
64
- } else {
65
- // Public page, show it but don't grant private navigation access
66
- document.body.classList.add('authenticated'); // Show body content
67
- updateAuthButton(false);
68
- }
69
- return;
70
- }
71
-
72
- // User is authenticated and has domain access - grant appropriate access
73
- console.log('User authenticated and authorized');
74
- document.body.classList.add('authenticated');
75
-
76
- // Grant private navigation access if private directory auth is enabled
77
- if (isPrivateDirectoryAuthEnabled || isGlobalAuthEnabled) {
78
- document.body.classList.add('has-private-access');
79
- }
80
-
81
- updateAuthButton(true);
82
-
83
- } catch (error) {
84
- console.error('Auth check failed:', error);
85
- const isPrivatePage = window.location.pathname.includes('/private/');
86
- if (isGlobalAuthEnabled || (isPrivateDirectoryAuthEnabled && isPrivatePage)) {
87
- redirectToLogin();
88
- } else {
89
- // Public page, show it anyway
90
- document.body.classList.add('authenticated');
91
- updateAuthButton(false);
92
- }
93
- }
94
- }
95
-
96
- // Redirect to login page
97
- function redirectToLogin() {
98
- const currentUrl = window.location.pathname + window.location.search;
99
- const loginUrl = '/login.html' + (currentUrl !== '/' ? '?redirect=' + encodeURIComponent(currentUrl) : '');
100
- window.location.href = loginUrl;
101
- }
102
-
103
- // Show access denied message
104
- function showAccessDenied() {
105
- document.body.classList.add('authenticated'); // Show the body
106
- document.body.innerHTML = `
107
- <div style="display: flex; justify-content: center; align-items: center; height: 100vh; font-family: Inter, sans-serif;">
108
- <div style="text-align: center; max-width: 400px;">
109
- <h1 style="color: #ef4444; margin-bottom: 1rem;">Access Denied</h1>
110
- <p style="color: #6b7280; margin-bottom: 2rem;">You don't have permission to view this documentation site.</p>
111
- <a href="/login.html" style="background: #3b82f6; color: white; padding: 0.75rem 1.5rem; border-radius: 0.5rem; text-decoration: none;">Try Different Account</a>
112
- </div>
113
- </div>
114
- `;
115
- }
116
-
117
- // Function to update auth button
118
- function updateAuthButton(isAuthenticated) {
119
- const authBtn = document.querySelector('.auth-btn');
120
- if (authBtn) {
121
- const icon = authBtn.querySelector('i');
122
- if (icon) {
123
- if (isAuthenticated) {
124
- icon.className = 'fas fa-sign-out-alt';
125
- authBtn.title = 'Logout';
126
- authBtn.href = '/logout.html';
127
- } else {
128
- icon.className = 'fas fa-sign-in-alt';
129
- authBtn.title = 'Login';
130
- authBtn.href = '/login.html';
131
- }
132
- }
133
- }
134
- }
135
-
136
- // Add auth button functionality
137
- document.addEventListener('DOMContentLoaded', function() {
138
- const authBtn = document.querySelector('.auth-btn');
139
- if (authBtn) {
140
- authBtn.addEventListener('click', async function(e) {
141
- // Check if we're logged in
142
- const { data: { user } } = await supabaseClient.auth.getUser();
143
- if (user) {
144
- // Logged in - sign out
145
- e.preventDefault();
146
- await supabaseClient.auth.signOut();
147
- window.location.href = '/logout.html';
148
- }
149
- // If not logged in, normal navigation to login page will occur
150
- });
151
- }
152
- });
153
-
154
- // Run auth check
155
- checkAuth();
156
-
157
- })();
@@ -1,525 +0,0 @@
1
- <!DOCTYPE html>
2
- <html lang="en">
3
- <head>
4
- <meta charset="UTF-8">
5
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
- <meta name="description" content="Claude + CLAUDE.">
7
- <title>Claude + CLAUDE.md Documentation Workflow Guide - Doc Builder</title>
8
-
9
- <meta name="author" content="Lindsay Smith">
10
- <meta name="keywords" content="documentation, markdown, static site generator, vercel, notion-style, claude, workflow, step">
11
- <meta name="robots" content="index, follow">
12
- <link rel="canonical" href="https://doc-builder-delta.vercel.app/claude-workflow-guide.html">
13
-
14
- <!-- Open Graph / Facebook -->
15
- <meta property="og:type" content="article">
16
- <meta property="og:url" content="https://doc-builder-delta.vercel.app/claude-workflow-guide.html">
17
- <meta property="og:title" content="Claude + CLAUDE.md Documentation Workflow Guide - Doc Builder">
18
- <meta property="og:description" content="Claude + CLAUDE.">
19
- <meta property="og:image" content="https://doc-builder-delta.vercel.app/og-default.png">
20
- <meta property="og:site_name" content="Doc Builder">
21
- <meta property="og:locale" content="en_US">
22
-
23
- <!-- Twitter Card -->
24
- <meta name="twitter:card" content="summary_large_image">
25
- <meta name="twitter:site" content="@planbbackups">
26
- <meta name="twitter:creator" content="@planbbackups">
27
- <meta name="twitter:title" content="Claude + CLAUDE.md Documentation Workflow Guide - Doc Builder">
28
- <meta name="twitter:description" content="Claude + CLAUDE.">
29
- <meta name="twitter:image" content="https://doc-builder-delta.vercel.app/og-default.png">
30
-
31
- <!-- Fonts -->
32
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet">
33
-
34
- <!-- Icons -->
35
- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css">
36
-
37
- <!-- Mermaid -->
38
- <script src="https://cdn.jsdelivr.net/npm/mermaid@10.6.1/dist/mermaid.min.js"></script>
39
-
40
- <!-- Styles -->
41
- <link rel="stylesheet" href="/css/notion-style.css">
42
-
43
- <!-- Favicon -->
44
- <link rel="icon" href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>📚</text></svg>">
45
-
46
- <script type="application/ld+json">
47
- {
48
- "@context": "https://schema.org",
49
- "@type": "TechArticle",
50
- "headline": "Claude + CLAUDE.md Documentation Workflow Guide",
51
- "description": "Claude + CLAUDE.",
52
- "author": {
53
- "@type": "Person",
54
- "name": "Lindsay Smith"
55
- },
56
- "publisher": {
57
- "@type": "Organization",
58
- "name": "Knowcode Ltd",
59
- "url": "https://knowcode.tech"
60
- },
61
- "datePublished": "2025-07-21T20:43:20.146Z",
62
- "dateModified": "2025-07-21T20:43:20.146Z",
63
- "mainEntityOfPage": {
64
- "@type": "WebPage",
65
- "@id": "https://doc-builder-delta.vercel.app/claude-workflow-guide.html"
66
- },
67
- "breadcrumb": {
68
- "@type": "BreadcrumbList",
69
- "itemListElement": [
70
- {
71
- "@type": "ListItem",
72
- "position": 1,
73
- "name": "Doc Builder",
74
- "item": "https://doc-builder-delta.vercel.app"
75
- },
76
- {
77
- "@type": "ListItem",
78
- "position": 2,
79
- "name": "Claude Workflow Guide",
80
- "item": "https://doc-builder-delta.vercel.app/claude-workflow-guide.html"
81
- }
82
- ]
83
- }
84
- }
85
- </script>
86
- </head>
87
- <body>
88
- <!-- Header -->
89
- <header class="header">
90
- <div class="header-content">
91
- <a href="/index.html" class="logo">Doc Builder</a>
92
-
93
- <div class="header-actions">
94
- <div class="deployment-info">
95
- <span class="deployment-date" title="Built with doc-builder v1.5.1">Last updated: Jul 21, 2025, 08:43 PM UTC</span>
96
- </div>
97
-
98
-
99
-
100
- <button id="theme-toggle" class="theme-toggle" aria-label="Toggle theme">
101
- <i class="fas fa-moon"></i>
102
- </button>
103
-
104
- <button id="menu-toggle" class="menu-toggle" aria-label="Toggle menu">
105
- <i class="fas fa-bars"></i>
106
- </button>
107
- </div>
108
- </div>
109
- </header>
110
-
111
- <!-- Preview Banner -->
112
- <div id="preview-banner" class="preview-banner">
113
- <div class="banner-content">
114
- <i class="fas fa-exclamation-triangle banner-icon"></i>
115
- <span class="banner-text">This documentation is a preview version - some content may be incomplete</span>
116
- <button id="dismiss-banner" class="banner-dismiss" aria-label="Dismiss banner">
117
- <i class="fas fa-times"></i>
118
- </button>
119
- </div>
120
- </div>
121
-
122
- <!-- Breadcrumbs -->
123
- <nav class="breadcrumbs" id="breadcrumbs">
124
- <!-- Breadcrumbs will be generated by JavaScript -->
125
- </nav>
126
-
127
- <!-- Main Content -->
128
- <div class="main-wrapper">
129
- <!-- Sidebar -->
130
- <aside class="sidebar">
131
- <div class="sidebar-header">
132
- <div class="filter-box">
133
- <input type="text" placeholder="Filter items..." class="filter-input" id="nav-filter">
134
- <i class="fas fa-search filter-icon"></i>
135
- </div>
136
- </div>
137
- <nav class="navigation">
138
-
139
- <div class="nav-section" data-level="0">
140
- <a class="nav-title expanded" href="/README.html" >
141
- <i class="fas fa-home"></i> Documentation
142
- </a>
143
- <div class="nav-content" >
144
- <a href="/README.html" class="nav-item" data-tooltip="@knowcode/doc-builder."><i class="fas fa-file-alt"></i> Overview</a>
145
- <a href="/claude-workflow-guide.html" class="nav-item active" data-tooltip="This guide demonstrates an efficient workflow for using Claude Code with a refined CLAUDE.md file to create high-quality documentation and deploy it..."><i class="fas fa-file-alt"></i> Claude Workflow Guide</a>
146
- <a href="/documentation-index.html" class="nav-item" data-tooltip="This directory contains additional documentation for the @knowcode/doc-builder project, organized by topic and purpose."><i class="fas fa-file-alt"></i> Documentation Index</a>
147
- <a href="/vercel-cli-setup-guide.html" class="nav-item" data-tooltip="This guide provides comprehensive instructions for installing and configuring the Vercel CLI across different operating systems and environments."><i class="fas fa-file-alt"></i> Vercel Cli Setup Guide</a>
148
- <a href="/vercel-first-time-setup-guide.html" class="nav-item" data-tooltip="This guide provides a detailed explanation of every prompt you&#039;ll encounter during the first-time Vercel setup process when using."><i class="fas fa-file-alt"></i> Vercel First Time Setup Guide</a></div></div>
149
- <div class="nav-section" data-level="1">
150
- <a class="nav-title collapsible" href="#" data-target="nav-guides-1" >
151
- <i class="fas fa-chevron-right collapse-icon"></i><i class="fas fa-folder"></i> Guides
152
- </a>
153
- <div class="nav-content collapsed" id="nav-guides-1">
154
- <a href="/guides/authentication-guide.html" class="nav-item" data-tooltip="This guide explains how to configure and use the built-in authentication feature in @knowcode/doc-builder to protect your documentation with basic..."><i class="fas fa-file-alt"></i> Authentication Guide</a>
155
- <a href="/guides/documentation-standards.html" class="nav-item" data-tooltip="This document defines the documentation standards and conventions for the @knowcode/doc-builder project."><i class="fas fa-file-alt"></i> Documentation Standards</a>
156
- <a href="/guides/seo-guide.html" class="nav-item" data-tooltip="@knowcode/doc-builder includes comprehensive SEO (Search Engine Optimization) features to help your documentation rank better in search results and..."><i class="fas fa-file-alt"></i> Seo Guide</a>
157
- <a href="/guides/troubleshooting-guide.html" class="nav-item" data-tooltip="This guide helps you resolve common issues when using @knowcode/doc-builder."><i class="fas fa-file-alt"></i> Troubleshooting Guide</a></div></div>
158
- </nav>
159
- <div class="resize-handle"></div>
160
- </aside>
161
-
162
- <!-- Content Area -->
163
- <main class="content">
164
- <div class="content-inner">
165
- <h1>Claude + CLAUDE.md Documentation Workflow Guide</h1>
166
- <p><strong>Generated</strong>: 2025-07-21 10:00 UTC<br><strong>Status</strong>: Complete<br><strong>Verified</strong>: ✅</p>
167
- <h2>Overview</h2>
168
- <p>This guide demonstrates an efficient workflow for using Claude Code with a refined CLAUDE.md file to create high-quality documentation and deploy it to Vercel using the @knowcode/doc-builder tool.</p>
169
- <h2>Workflow Overview</h2>
170
- <div class="mermaid-wrapper">
171
- <div class="mermaid-title">Diagram</div>
172
- <div class="mermaid">graph TD
173
- A[Start Project] --> B[Setup CLAUDE.md]
174
- B --> C[Configure doc-builder]
175
- C --> D[Create Documentation with Claude]
176
- D --> E[Build Static Site]
177
- E --> F[Deploy to Vercel]
178
- F --> G[Live Documentation]
179
-
180
- B -.-> H[Refine Instructions]
181
- H -.-> D
182
-
183
- D --> I{Review Quality}
184
- I -->|Needs Improvement| H
185
- I -->|Good| E
186
-
187
- style A fill:#e1f5fe
188
- style G fill:#c8e6c9
189
- style H fill:#fff3e0</div>
190
- </div>
191
- <h2>Step 1: Setting Up CLAUDE.md</h2>
192
- <h3>1.1 Project-Level CLAUDE.md</h3>
193
- <p>Create a <code>CLAUDE.md</code> file in your project root with specific instructions for documentation:</p>
194
- <pre><code class="language-markdown"># CLAUDE.md - [Your Project Name]
195
-
196
- ## Documentation Standards
197
-
198
- ### Document Structure
199
- - All documentation goes in the `/docs` directory
200
- - Use hierarchical folder structure for organization
201
- - Follow naming convention: `{component}-{topic}-guide.md`
202
-
203
- ### Content Requirements
204
- - Include mermaid diagrams for complex workflows
205
- - Mark verified (✅) vs speculated (❓) information
206
- - Add timestamps to all documents
207
- - Include practical examples
208
-
209
- ### Writing Style
210
- - Use clear, concise language
211
- - Target intermediate technical audience
212
- - Include code examples with syntax highlighting
213
- - Add troubleshooting sections
214
-
215
- ### Metadata Format
216
- </code></pre>
217
- <p><strong>Generated</strong>: YYYY-MM-DD HH:MM UTC<br><strong>Status</strong>: Draft/Complete<br><strong>Verified</strong>: ✅/❓</p>
218
- <pre><code>
219
- </code></pre>
220
- <h3>1.2 Global CLAUDE.md Best Practices</h3>
221
- <p>Your global <code>~/.claude/CLAUDE.md</code> should include:</p>
222
- <div class="mermaid-wrapper">
223
- <div class="mermaid-title">Diagram</div>
224
- <div class="mermaid">graph LR
225
- A[Global CLAUDE.md] --> B[Document Standards]
226
- A --> C[Git Workflow]
227
- A --> D[Quality Checks]
228
- A --> E[Security Practices]
229
-
230
- B --> B1[Naming Conventions]
231
- B --> B2[Markdown Standards]
232
- B --> B3[Diagram Requirements]
233
-
234
- C --> C1[Commit Frequency]
235
- C --> C2[Branch Strategy]
236
-
237
- D --> D1[Verification Marks]
238
- D --> D2[Changelog Updates]
239
-
240
- E --> E1[No Credentials]
241
- E --> E2[Access Controls]</div>
242
- </div>
243
- <h2>Step 2: Initialize doc-builder</h2>
244
- <pre><code class="language-bash"># Install doc-builder
245
- npm install -D @knowcode/doc-builder
246
-
247
- # Initialize configuration
248
- npx doc-builder init
249
- </code></pre>
250
- <h3>2.1 Configure doc-builder.config.js</h3>
251
- <pre><code class="language-javascript">module.exports = {
252
- siteName: &#39;Your Project Documentation&#39;,
253
- siteDescription: &#39;Comprehensive documentation for Your Project&#39;,
254
- docsDir: &#39;docs&#39;,
255
- outputDir: &#39;html&#39;,
256
- features: {
257
- authentication: false, // Set true for private docs
258
- changelog: true,
259
- mermaid: true,
260
- darkMode: true
261
- }
262
- };
263
- </code></pre>
264
- <h2>Step 3: Documentation Creation Workflow with Claude</h2>
265
- <h3>3.1 Effective Prompting Strategy</h3>
266
- <div class="mermaid-wrapper">
267
- <div class="mermaid-title">Diagram</div>
268
- <div class="mermaid">sequenceDiagram
269
- participant User
270
- participant Claude
271
- participant CLAUDE.md
272
- participant Documentation
273
-
274
- User->>Claude: Request documentation
275
- Claude->>CLAUDE.md: Check project standards
276
- CLAUDE.md-->>Claude: Return guidelines
277
- Claude->>Documentation: Create/Update docs
278
- Claude->>User: Confirm completion
279
- User->>Claude: Review & refine
280
- Claude->>Documentation: Apply refinements</div>
281
- </div>
282
- <h3>3.2 Example Documentation Requests</h3>
283
- <h4>Initial Architecture Documentation</h4>
284
- <pre><code>&quot;Create comprehensive architecture documentation for our authentication system. Include:
285
- - System overview with mermaid diagrams
286
- - Component interactions
287
- - API endpoints
288
- - Security considerations
289
- - Deployment architecture&quot;
290
- </code></pre>
291
- <h4>API Documentation</h4>
292
- <pre><code>&quot;Document all REST API endpoints in our user service. For each endpoint include:
293
- - HTTP method and path
294
- - Request/response schemas
295
- - Authentication requirements
296
- - Example requests with curl
297
- - Error responses&quot;
298
- </code></pre>
299
- <h4>Setup Guide</h4>
300
- <pre><code>&quot;Create a detailed setup guide for new developers including:
301
- - Prerequisites
302
- - Environment setup steps
303
- - Configuration options
304
- - Common issues and solutions
305
- - Development workflow&quot;
306
- </code></pre>
307
- <h3>3.3 Claude Interaction Best Practices</h3>
308
- <ol>
309
- <li><strong>Be Specific</strong>: Provide clear requirements and expected structure</li>
310
- <li><strong>Iterate</strong>: Review generated content and request refinements</li>
311
- <li><strong>Verify</strong>: Ask Claude to mark verified vs speculated information</li>
312
- <li><strong>Examples</strong>: Request concrete examples and code snippets</li>
313
- <li><strong>Diagrams</strong>: Explicitly request mermaid diagrams for visual clarity</li>
314
- </ol>
315
- <h2>Step 4: Building Documentation Site</h2>
316
- <h3>4.1 Development Workflow</h3>
317
- <div class="mermaid-wrapper">
318
- <div class="mermaid-title">Diagram</div>
319
- <div class="mermaid">graph LR
320
- A[Write Docs] --> B[Preview Locally]
321
- B --> C{Looks Good?}
322
- C -->|No| A
323
- C -->|Yes| D[Build Site]
324
- D --> E[Test Build]
325
- E --> F{All Good?}
326
- F -->|No| A
327
- F -->|Yes| G[Ready to Deploy]
328
-
329
- style A fill:#fff3e0
330
- style G fill:#c8e6c9</div>
331
- </div>
332
- <h3>4.2 Commands</h3>
333
- <pre><code class="language-bash"># Start development server
334
- npm run dev:docs
335
-
336
- # Build static site
337
- npm run build:docs
338
-
339
- # Preview built site
340
- npx serve html
341
- </code></pre>
342
- <h2>Step 5: Deploying to Vercel</h2>
343
- <h3>5.1 First-Time Setup</h3>
344
- <pre><code class="language-bash"># Deploy to Vercel (interactive)
345
- npx doc-builder deploy
346
-
347
- # Or with npm script
348
- npm run deploy:docs
349
- </code></pre>
350
- <h3>5.2 Vercel Configuration</h3>
351
- <p>The tool automatically creates <code>vercel.json</code>:</p>
352
- <pre><code class="language-json">{
353
- &quot;outputDirectory&quot;: &quot;html&quot;,
354
- &quot;routes&quot;: [
355
- {
356
- &quot;src&quot;: &quot;/(.*)&quot;,
357
- &quot;dest&quot;: &quot;/$1&quot;
358
- }
359
- ]
360
- }
361
- </code></pre>
362
- <h3>5.3 Deployment Workflow</h3>
363
- <div class="mermaid-wrapper">
364
- <div class="mermaid-title">Diagram</div>
365
- <div class="mermaid">stateDiagram-v2
366
- [*] --> LocalDevelopment
367
- LocalDevelopment --> BuildDocs: npm run build:docs
368
- BuildDocs --> TestLocally: npx serve html
369
- TestLocally --> Deploy: npx doc-builder deploy
370
- Deploy --> VercelProcessing
371
- VercelProcessing --> LiveSite: Success
372
- VercelProcessing --> ErrorHandling: Failed
373
- ErrorHandling --> LocalDevelopment: Fix issues
374
- LiveSite --> [*]</div>
375
- </div>
376
- <h2>Step 6: Continuous Documentation Updates</h2>
377
- <h3>6.1 Update Workflow</h3>
378
- <div class="mermaid-wrapper">
379
- <div class="mermaid-title">Diagram</div>
380
- <div class="mermaid">graph TD
381
- A[Code Changes] --> B{Docs Needed?}
382
- B -->|Yes| C[Update Documentation]
383
- B -->|No| End[End]
384
- C --> D[Use Claude for Updates]
385
- D --> E[Review Changes]
386
- E --> F[Build & Test]
387
- F --> G[Deploy Updates]
388
- G --> H[Update CHANGELOG.md]
389
- H --> End
390
-
391
- style A fill:#ffebee
392
- style G fill:#e8f5e9</div>
393
- </div>
394
- <h3>6.2 Maintaining Documentation Quality</h3>
395
- <ol>
396
- <li><strong>Regular Reviews</strong>: Schedule periodic documentation reviews</li>
397
- <li><strong>Automated Checks</strong>: Add documentation linting to CI/CD</li>
398
- <li><strong>User Feedback</strong>: Create feedback mechanism for documentation</li>
399
- <li><strong>Version Tracking</strong>: Maintain documentation versions with code versions</li>
400
- </ol>
401
- <h2>Advanced CLAUDE.md Refinements</h2>
402
- <h3>7.1 Project-Specific Instructions</h3>
403
- <pre><code class="language-markdown">## Project-Specific Documentation Rules
404
-
405
- ### Component Documentation
406
- - Each major component needs its own guide
407
- - Include architecture decisions
408
- - Document integration points
409
- - Add performance considerations
410
-
411
- ### Code Examples
412
- - Use TypeScript for all examples
413
- - Include error handling
414
- - Show both correct and incorrect usage
415
- - Add inline comments for clarity
416
-
417
- ### Diagrams
418
- - Use mermaid for all flow diagrams
419
- - Include sequence diagrams for APIs
420
- - Add state diagrams for complex logic
421
- - Create entity relationship diagrams for data models
422
- </code></pre>
423
- <h3>7.2 Documentation Templates</h3>
424
- <p>Create templates in your CLAUDE.md:</p>
425
- <pre><code class="language-markdown">## Documentation Templates
426
-
427
- ### API Endpoint Template
428
- </code></pre>
429
- <h2>[HTTP Method] /api/[endpoint]</h2>
430
- <p><strong>Purpose</strong>: [Brief description]</p>
431
- <h3>Request</h3>
432
- <ul>
433
- <li><strong>Headers</strong>: <ul>
434
- <li><code>Authorization: Bearer [token]</code></li>
435
- <li><code>Content-Type: application/json</code></li>
436
- </ul>
437
- </li>
438
- <li><strong>Body</strong>:<pre><code class="language-json">{
439
- &quot;field&quot;: &quot;value&quot;
440
- }
441
- </code></pre>
442
- </li>
443
- </ul>
444
- <h3>Response</h3>
445
- <ul>
446
- <li><strong>Success (200)</strong>:<pre><code class="language-json">{
447
- &quot;data&quot;: {}
448
- }
449
- </code></pre>
450
- </li>
451
- <li><strong>Error (4xx/5xx)</strong>:<pre><code class="language-json">{
452
- &quot;error&quot;: &quot;Description&quot;
453
- }
454
- </code></pre>
455
- </li>
456
- </ul>
457
- <h3>Examples</h3>
458
- <pre><code class="language-bash">curl -X POST https://api.example.com/endpoint \
459
- -H &quot;Authorization: Bearer token&quot; \
460
- -d &#39;{&quot;field&quot;: &quot;value&quot;}&#39;
461
- </code></pre>
462
- <pre><code>
463
- ## Best Practices Summary
464
-
465
- ### Documentation Creation
466
- 1. ✅ Use CLAUDE.md to maintain consistency
467
- 2. ✅ Include visual diagrams for complex concepts
468
- 3. ✅ Provide practical examples
469
- 4. ✅ Mark verification status
470
- 5. ✅ Keep documentation close to code
471
-
472
- ### Claude Interaction
473
- 1. ✅ Provide clear, specific requests
474
- 2. ✅ Reference existing patterns
475
- 3. ✅ Request iterative improvements
476
- 4. ✅ Verify technical accuracy
477
- 5. ✅ Ask for troubleshooting sections
478
-
479
- ### Deployment
480
- 1. ✅ Test locally before deploying
481
- 2. ✅ Use preview deployments first
482
- 3. ✅ Configure custom domains
483
- 4. ✅ Enable HTTPS
484
- 5. ✅ Monitor deployment health
485
-
486
- ## Common Issues and Solutions
487
-
488
- ### Issue 1: Claude Not Following Standards
489
- **Solution**: Refine CLAUDE.md with more specific examples and explicit requirements
490
-
491
- ### Issue 2: Documentation Build Fails
492
- **Solution**: Check markdown syntax, ensure all links are valid, verify mermaid syntax
493
-
494
- ### Issue 3: Vercel Deployment Issues
495
- **Solution**: Check vercel.json configuration, ensure output directory is correct
496
-
497
- ### Issue 4: Navigation Not Generated
498
- **Solution**: Verify folder structure follows conventions, check for special characters in filenames
499
-
500
- ## Conclusion
501
-
502
- This workflow enables efficient, high-quality documentation creation by:
503
- - Leveraging Claude&#39;s capabilities with clear guidelines
504
- - Using doc-builder for beautiful, searchable output
505
- - Deploying seamlessly to Vercel for instant access
506
- - Maintaining consistency through CLAUDE.md refinements
507
-
508
- The key to success is iterative refinement of your CLAUDE.md file to capture your team&#39;s specific documentation needs and standards.
509
-
510
- ## Document History
511
-
512
- | Date | Author | Changes |
513
- |------|--------|---------|
514
- | 2025-07-21 | Claude | Initial creation |
515
- </code></pre>
516
-
517
- </div>
518
- </main>
519
- </div>
520
-
521
- <!-- Scripts -->
522
- <script src="/js/main.js"></script>
523
-
524
- </body>
525
- </html>