This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
ut.code(); Learn is a web technology learning platform built with Docusaurus. It provides educational materials for web development, covering HTML, CSS, JavaScript, Node.js, React, and more advanced topics. The content is written in MDX format and automatically generates a documentation website.
npm ci # Install dependencies (preferred over npm install)
npm start # Start development server with hot reload
npm run build # Build production site
npm run serve # Serve built site locallynpm run format # Format code with Prettier
npm run format:check # Check code formattingAlways run these commands before committing:
npm run format
npm run builddocs/- Main content directory with MDX files1-trial-session/- Beginner tutorials2-browser-apps/- Browser-based applications3-web-servers/- Server-side development4-advanced/- Advanced topics (TypeScript, React, bundlers)5-team-development/- Team development practices_samples/- Code examples within each section
src/- Docusaurus customizationscomponents/- Custom React components for MDXcss/- Custom stylingpages/- Static pagestheme/- Theme customizations
static/- Static assets (images, etc.)
- All content files are
index.mdxwithin their respective directories - Sidebar navigation is auto-generated based on directory structure
- Each section contains practical code samples in
_samples/subdirectories
The following custom components are available for use in MDX files:
<Term>- Add popup explanations for technical terms<Answer>- Collapsible answer sections for exercises<ViewSource>- Buttons to view code on GitHub and CodeSandbox<ExternalVideoPlayer>- Embed external videos<SlideShow>- Create image slideshows
Code examples are organized in _samples/ directories within each topic:
- Each sample has its own
package.jsonwith dependencies - Samples are referenced from main content using
<ViewSource>component - Many samples are runnable Node.js or browser applications
- Edit
index.mdxfiles in the appropriatedocs/subdirectory - Use MDX syntax (Markdown + JSX components)
- Math expressions supported via KaTeX (use
$$for block math,$for inline) - Mermaid diagrams supported
- Code highlighting with Prism.js
- Requires Node.js >= 18.0 (specified in
package.json) - Uses
.nvmrcfile for version management
- Uses Prettier for code formatting
- VSCode configured to use Prettier as default formatter
- Empty
.prettierrc.jsonuses default Prettier settings