How to Turn Code Written by Claude into a Real Service

Computing/Software3 min read

TuBrief Editorial Written with AI assistance from the source video. The video is the authority. Source video: Insane Claude Design Skills You Need To Build Beautiful Websites · AI LABS

Prevent Design Fragmentation

HTML files generated by Claude look decent at first. However, once you go beyond three pages, maintaining them becomes a nightmare. Opening 10 files just to change a single font size is a waste of time. Separate your code.

  1. Create a project folder. Divide your files: CSS in /assets/css, images in /assets/img, and layouts in /components.
  2. Use only lowercase letters and hyphens for filenames, such as main-header.html. This reduces the chance of Claude confusing file paths.
  3. Include a <link> tag in the <head> of your main HTML file to manage styles centrally.

By doing this, you only need to fix a header once, and the changes are immediately applied across all pages. You won't have to spend time editing files repeatedly.

Standardize Your Color Palette with CSS Variables

Do not hardcode color codes directly into every component. You don't want to sift through thousands of lines every time you want to change a button color. Instead, use CSS variables.

  1. Open your /assets/css/global.css file.
  2. Define your 3 core colors like this: :root { --main-color: #000000; --sub-color: #ffffff; }.
  3. When writing styles, use them like: background-color: var(--main-color);.

If your brand colors change later, just update a single file for 3 seconds. The button colors on every page will change at once. This is much more efficient than manually editing the design every time.

Verify Instantly in a Local Environment

If you constantly modify code and refresh the browser, you will lose your focus. Install the Live Server extension for VS Code.

  1. Install Live Server in VS Code and click the "Go Live" button at the bottom.
  2. Open your site in the browser, right-click, and select "Inspect" to open Developer Tools.
  3. Adjust margins or font sizes in the Elements tab on the fly. Simply copy the updated values back into your CSS files.

See visible changes in real-time without refreshing. This cuts your design iteration time in half.

Enforce Standards for Claude

Claude writes code differently every time you ask. Establish rules before you start chatting. Create a CLAUDE.md file in your project root directory.

  1. Write down your CSS variable rules and folder structure in CLAUDE.md.
  2. Define frequently used button or card shapes in XML format (e.g., code).
  3. When asking Claude for a new screen, just add one sentence: "Follow the rules in CLAUDE.md."

This significantly reduces the chances of the AI arbitrarily complicating your code.

Automate Deployment with Vercel

Don't worry about server settings or complex configurations. With Vercel, your website works as soon as you push your code.

  1. Push your code to GitHub.
  2. Connect your GitHub account on the Vercel website and create a project.
  3. Every time you push code to GitHub thereafter, Vercel will update the site within 45 seconds.

There is no need to manage servers yourself. A domain address is generated automatically, and if a problem occurs, you can roll back to a previous version at any time. Upload your code now.

Related Video

Insane Claude Design Skills You Need To Build Beautiful Websites

AI LABS14:14

More from the community

Comments

Log in to leave a comment.

No comments yet.