AI Coding Tools Tested: Building an E-Commerce Storefront from Scratch
A hands-on evaluation of AI coding tools across four capability types, using a 10-page e-commerce frontend as a common benchmark. The article lays out a reproducible testing framework and clear acceptance criteria, explains why building a complete site from zero is far harder than generating a single component, and summarizes how each tool type performs on completeness, consistency, and maintainability. It closes with practical engineering guidance—structured prompts, staged generation with checkpoints, architectural constraints, data-layer decoupling, and an automated code QA pipeline—for turning task-level AI code generation into deliverable, maintainable software. Suitable for developers and teams choosing an AI coding tool or looking to integrate one into their workflow.
AI Coding Tools Tested: Building an E-Commerce Storefront from Scratch
1. Introduction: From “Completing Code” to “Completing Tasks”
Over the past two years, the capability boundary of AI coding tools has kept expanding, moving through roughly three stages:
- Inline completion: predicting the next line or block of code based on the context of the current file. This is the most basic form, aimed mainly at reducing mechanical typing.
- Conversational generation: developers describe a need in natural language and the tool generates functions, components, or scripts. The human–AI interaction is mostly “question-and-answer plus snippets.”
- Task-level generation: the tool takes a fairly complete requirement, decomposes the steps on its own, writes code across multiple files, and iterates fixes based on runtime results. The developer’s role shifts from “writing line by line” to “defining requirements and acceptance criteria.”
For developers, the most valuable leap happens at the third stage. But among AI coding tools that can be used directly without extra network configuration, the underlying models and product forms differ significantly from one product to another. Marketing claims have become increasingly similar, while real-world usability varies widely, so promotional material alone is hard to judge.
The most effective way to test whether a tool has “task-level generation” ability is to give it an engineering task with a clear goal, well-defined deliverables, and quantifiable acceptance criteria. This article uses “building an e-commerce frontend storefront from zero” as a unified task to test and analyze four representative forms of AI coding capability, and extracts a reusable evaluation method along with practical recommendations.
2. Test Design and Evaluation Framework
2.1 Test Task: A 10-Page E-Commerce Frontend
The task requires using a component-based frontend framework to build a storefront with the following 10 pages:
| Module | Page | Core features |
|---|---|---|
| Main shopping flow | Home (product list) | Product display, category/search, add to cart |
| Product detail | Product info, spec selection, add to cart, buy now | |
| Checkout | Shipping info, order confirmation, submit order | |
| Payment success | Result feedback, order redirect | |
| Account | Login | Account/password validation, redirect |
| Register | Input validation, registration success guidance | |
| User center | Overview (Dashboard) | Orders/balance/coupons overview, common entries |
| Orders | Order list, status filter, detail view | |
| Wallet (coupon pack) | Balance display, coupon list, usage entry | |
| Settings | Profile, security settings, preference config |
This task may look like an ordinary “multi-page site,” but it is actually a comprehensive test:
- Scale: 10 pages with multiple forms and lists; generating them in one pass places heavy demands on context length and task-planning ability.
- Interdependence: shared state exists across pages (cart, login state, balance); the pages are not isolated from one another.
- Conventions: visual style, component usage, and directory structure must be globally consistent, testing consistency and long-range memory.
- Details: edge cases such as empty states, loading states, error states, and form validation often determine whether the product can truly ship.
2.2 Acceptance Criteria
A unified acceptance threshold was set:
- Dependencies install, the project starts, and the console shows no blocking errors;
- All 10 pages load correctly and the core shopping flow can be completed end to end;
- Forms provide basic validation;
- The layout is basically usable at both desktop and mobile viewports.
2.3 Evaluation Dimensions
| Dimension | Focus | Suggested weight |
|---|---|---|
| Task completion | Number of pages, feature coverage | 25% |
| First-pass quality | Whether the first version runs, number of errors, fix cost | 20% |
| UI and interaction | Visual consistency, interaction details, form validation | 15% |
| Multi-device support | Responsive layout, mobile usability | 10% |
| Code quality | Structural soundness, separation of concerns, maintainability | 20% |
| Execution efficiency | Generation speed, response stability | 10% |
To reduce subjective bias, several people should score independently and average the results; for each issue, record the type, location, and number of rounds needed to fix it, forming a quantifiable “defect list.”
3. Difficulty Analysis: Why “Zero to One” Is Far Harder Than “Writing a Component”
In practice, what determines success is not the generation quality of any single page, but the following three engineering challenges.
3.1 Difficulty 1: Site Completeness
Completeness problems typically show up as “a full skeleton with missing flesh”:
- The page count falls short, or empty shell pages are generated;
- The navigation chain between pages breaks—no return after login, no login check before checkout;
- Only the happy path is present, with no empty states, loading states, error states, or boundary handling (such as zero amount, zero stock, or overlong form input);
- Information density is uneven—list pages are rich, but detail and wallet pages are too thin.
Completeness is essentially “the completeness of task decomposition.” If a tool merely treats the requirement as a whole and “continues writing,” it is prone to attending to one part while neglecting another.
3.2 Difficulty 2: Overall Consistency
Ten pages generated in the same conversation often look “as if written by ten different people”:
- Visual inconsistency: no unified primary color, inconsistent button styles, arbitrary choices of corner radius and spacing;
- Interaction inconsistency: some forms have validation and some do not; some show feedback after submission and some jump straight away;
- Naming and structural inconsistency: mixed component naming styles, with business logic tangled into presentation logic.
Consistency requires defining global conventions up front (design tokens, naming rules, component hierarchy) before generation begins, and continuously enforcing them during generation. Otherwise, the longer the context, the more likely the model is to “drift.”
3.3 Difficulty 3: Maintainability
From the test samples, this is the most common and most easily overlooked problem:
- Mock data is hard-coded directly into page components and tightly coupled with the view, so wiring in real APIs later requires large-scale changes;
- Directories for state management, context, and so on are reserved but left empty—“similar in form but absent in substance”;
- Styles are not split by page, or lack unified variables and a theme file;
- The directory structure is non-standard—for example, a duplicate nested directory with the same name appears, so the build tool cannot correctly resolve the entry file and the project fails to start outright.
Truly deliverable code should keep changes localized when “replacing the data layer, extending pages, or adjusting to a design revision.” This is exactly the signal most worth watching when assessing the quality of AI-generated code.
4. How the Four Capability Types Performed
Across the tests, the tools’ performance can be grouped into four capability types. The table below is a qualitative summary based on the test samples; it reflects the common tendency of a given capability class, not a conclusion about any specific product. Different versions and prompts can produce significant differences.
| Type | Core characteristics | Relative strengths | Main risks |
|---|---|---|---|
| A Interactive-guided AI IDE | Friendly visual interface, task-style generation | High first-pass completeness, stable responses | Weak mobile support, coupled data layer |
| B AI-first editor | Continues the interaction paradigm of general-purpose AI editors, with privacy mode and other options | Complete form validation, rich detail info | Many first-version errors, rough visual details |
| C Multi-agent orchestration | Offers multiple agents/modes, for fast generation and complex task decomposition respectively | Dedicated path for complex tasks | Poor mode choice can cause structural mess or rework |
| D Completion and chat | Focused on inline completion and snippet Q&A | Lightweight, focused | Poor at overall architecture and cross-file consistency |
4.1 Type A: Interactive-Guided AI IDE
UI and interaction: onboarding is fairly complete, and the interface is friendly, so it does not leave users feeling an aloof distance.
Generation: it uses a whole-package “task mode” generation, able to produce a complete site in one pass; server responses are relatively fast, with no obvious lag during generation.
Output quality: the output leans overall toward a mobile layout. Pages such as the product list, checkout, and user center are relatively complete, but the login and registration forms distort on narrow screens; images generally use placeholders, and the product detail page carries little information.
Code quality: styles and logic are basically separated, but the overall architecture is simple; mock data is coupled directly into components, so wiring in real APIs later requires considerable rework.
Improvement suggestions: explicitly state “desktop-first, mobile-adaptive” in the task description, require images to use configurable URLs, and consolidate data access into an independent data layer.
4.2 Type B: AI-First Editor
Interaction design: the interaction logic continues the approach of general-purpose AI editors, offering privacy mode and other options that give some control over the scope of code upload.
Generation: the first version runs but has errors, and only displays correctly after several rounds of fixes; generation is slow, with noticeably long waits on long tasks.
Output quality: form validation is relatively complete, and the product detail page is richer than Type A; but the overall look is plain, it is not mobile-adaptive, and it has small defects such as “white text on a white background” that makes button content invisible.
Code quality: there is an awareness of style separation, but styles are not split into separate files per module; positions for state management, context, and so on are reserved in the directory but the content is empty; overall it is still at a “good enough to look at” level, with substantial rework needed later.
Improvement suggestions: specify responsive breakpoints and color constraints, list the “reserved but empty” modules as acceptance items, and require the tool to complete a minimal implementation of core state management in the first version.
4.3 Type C: Multi-Agent Orchestration
Capability structure: it offers multiple agents or modes, corresponding to different scenarios such as fast code generation and complex task decomposition.
Fast generation mode: fast, but the generated project directory is messy, with the “nested folder inside a folder of the same name” problem appearing, so the project cannot run at all.
Complex task mode: it claims to handle more complex tasks, but server responses are slow; the project generated in this mode does start, but has no shortage of errors, and multiple fix attempts fail to converge, so it ultimately had to be abandoned.
Takeaway: the more modes there are, the higher the selection cost. Users must understand the applicable scope of each mode and also budget for the rework cost of “choosing the wrong mode.”
4.4 Type D: Completion and Chat
Tools of this kind excel at snippet-level code generation, code explanation, and Q&A, but for cross-file, long-cycle tasks like “building a complete site from zero,” developers usually have to take on the architecture design and integration work themselves. This is not a lack of ability but a difference in positioning: they are better suited as an accelerator for everyday coding rather than a full-site outsourcer.
5. A Reproducible Evaluation Method
Personal experience is easily influenced by prompt-writing skill, personal preferences, and chance factors. To make tool selection persuasive, it is best to turn the evaluation into a reproducible process:
- Fixed task set: prepare tasks of different granularities—“snippet generation, module refactoring, building from zero, defect fixing”—covering real work scenarios.
- Unified prompts and starting conditions: use the same requirements document, the same initial directory, and the same dependency versions for all tools.
- Set a fix limit: for example, allow 3 fix rounds per tool, and record “the minimum number of rounds needed to reach a runnable state.”
- Record results in a structured way: save each round’s conversation, terminal logs, and screenshots, and count by issue type.
- Multi-person blind review: reviewers do not know which tool produced a result, and score against a unified rubric.
- Continuous retesting: models and products iterate frequently, so evaluation conclusions should be updated regularly to avoid a “one-time verdict.”
6. Engineering Practices That Make Task-Level Generation Usable
Regardless of which type of tool is used, the output of task-level generation needs to be “constrained, checked, and verified.” The following practices come from both the positive and negative experiences in testing.
6.1 Replace One-Line Requirements with Structured Prompts
Expand “write a shopping site with some framework” into “role + goal + scope + conventions + acceptance criteria + output format”:
[Role] Senior frontend engineer[Goal] Build an e-commerce frontend storefront from zero, with 10 pages:home, product detail, checkout, payment success, login, register,and user center (overview / orders / wallet / settings).[Technical constraints]- Use a unified scaffold, with components, pages, services, and state organized in layers- Desktop-first, must adapt to a 375px-wide mobile viewport- Colors, spacing, and corner radius defined uniformly in theme variables; no hard-coding inside components- Mock data placed uniformly in the data layer; the view layer does not reference it directly[Output requirements]- First output the directory structure and routing design, then write code after confirmation- Each page must cover loading, empty, and error states- Self-check when done: buildable, startable, all 10 pages accessible
6.2 Stage Generation and Set Checkpoints
Break the task into stages—“skeleton → design tokens and shared components → core pages → user center → integration and self-check”—and review each stage’s output manually before moving to the next. This surfaces “consistency drift” and “structural mess” early, preventing errors from accumulating endlessly in the context.
6.3 Control Structure with Specified Constraints
Specify the directory convention clearly in the prompt or a project-standards document, for example:
src/├── components/ # shared UI components (button, input, card)├── features/ # organized by business domain (product / cart / order / user)│ └── product/│ ├── ProductList.tsx│ └── ProductDetail.tsx├── services/ # data access layer, uniformly connecting mock or real APIs├── stores/ # global state (cart, login state)├── theme/ # design tokens and global styles└── router/ # routing and permission guards
The more explicit the constraints, the less room there is for the model to freely improvise and create a structural mess.
6.4 Data Layer First: Decouple Views from Data
The page layer should not depend directly on hard-coded mock data. Define the interface contract first, then use an adapter layer to switch data sources:
// services/product.tsexport interface Product {id: string;name: string;price: number; // stored in cents to avoid floating-point errorscover: string;stock: number;}// The data access layer hides the data source, so connecting a real API// requires no changes to page componentsexport async function fetchProducts(params: { keyword?: string; page: number }): Promise<Product[]> {const res = await http.get<Product[]>('/products', { params });return res.data;}
6.5 Build an Automated “AI Code QA” Pipeline
The main risk of AI-generated code is not “whether it can write,” but “whether it is maintainable and secure.” It is advisable to bake the following checks into the commit flow:
- type checks, linting, and unit tests;
- build-artifact size checks and dependency version locking;
- scans for hard-coded keys and sensitive-information leaks;
- automated smoke tests for critical paths (browse → checkout → payment success).
7. Enterprise Perspective: Adoption Considerations for Intelligent Coding Tools
For teams and enterprise users, selection cannot focus only on “how fast it generates”; a comprehensive assessment is needed:
- Data and compliance: whether code will be used for model training, whether privacy mode or private deployment is supported, and whether industry regulatory requirements can be met;
- Team fit: whether team-level configuration, unified prompt templates, and a knowledge base are supported, so generation style stays consistent with team standards;
- Integrability: whether it connects with code hosting, continuous integration, and code review flows, embedding “generation” into the development pipeline rather than leaving it on the outside;
- Cost and efficiency: a balanced measure of subscription cost against adoption rate, defect rate, and review time;
- Knowledge accumulation: turning effective prompts, project skeletons, and acceptance checklists into team assets, reducing dependence on individual experience.
Take Baidu AI Cloud as an example: enterprise-grade intelligent coding tools are typically built around capabilities such as code completion, code-comment generation, unit-test generation, and code explanation and review assistance, and support security options such as enterprise knowledge-base integration and private deployment. For specific features and supported scope, please refer to the official documentation.
8. Summary
The test built around “a 10-page e-commerce site from zero” leads to the following conclusions:
- The four capability types each have their own emphasis: guided tools achieve higher first-pass completion, AI-first editors do better on forms and information completeness, orchestration tools provide a dedicated path for complex tasks but at higher selection cost, and completion tools are better suited to accelerating everyday coding.
- No type can deliver with “just one prompt.” Engineering issues such as cross-page consistency, data-layer decoupling, and responsive adaptation still require developers to actively constrain and gatekeep.
- Evaluation should return to quantifiable metrics—completion, first-pass rate, defect density, and rework cost—rather than the subjective impression of “easy to use.”
- The value of intelligent coding tools ultimately depends on whether they can be embedded into the “requirement → generation → review → verification → delivery” development process and continuously produce reusable engineering assets.
Tools will keep iterating, but expressing requirements in a structured way, drawing architectural boundaries clearly, and insisting on code review and automated verification are the truly irreplaceable core abilities of developers in the age of AI.
