Front-End Code Generation in Practice: Login, List, and Form Page Gaps
This article presents a reproducible evaluation of AI coding tools on three common front-end page types: login, list, and form pages. It documents the environment and prompt information that must be recorded, compares completion across page types, and highlights where generated code missed filtering, pagination linkage, field dependencies, async validation, and cross-field validation. The findings apply only to this sample: standardized login pages were largely complete, while complex list and form rules required manual implementation and pre-launch review. Teams can reuse the checklist and comparison table to assess generated code, wait times, and launch risks.
Intelligent coding tools have moved from generating code snippets to attempting to deliver complete front-end projects. When teams choose tools and plan schedules, the key questions are which pages a model can complete, where it will miss requirements, and whether the generated result can go directly to production. This article uses login, list, and form pages as samples to document a reproducible evaluation method and record the main observations from practice. It does not provide generalized performance rankings; all conclusions are limited to the scope of this sample.
1. Experiment Setup and Recording Requirements
Whether or not a team replicates this article, the report should state the following information. Otherwise, the results cannot be verified:
- Model name and version number, as well as key parameters such as temperature at invocation.
- Front-end framework and major dependency versions, such as build tool, UI component library, and router library.
- Number of pages in the requirements document, number of pages to implement, and total number of fields.
- Full prompt text, including additional constraints and examples.
- Evaluation items and success criteria. The criteria should be completed independently by at least two reviewers and then compared.
- Date of time measurement, network environment, and concurrency count, with at least three measurements recorded.
2. Baseline Page: Login Page Completeness
The login page includes a carousel, basic layout, account and password input fields, and required-field and format validation. In this sample, the model was able to identify these structures and generate component code that conformed to common front-end conventions. The page functionality was basically complete, with no obvious logic gaps.
This type of page has a standard structure and mature interaction patterns, so the model output showed relatively high completeness. However, runnable functionality does not mean the page is ready for launch. The form submission logic, token storage approach, and error message copy in the generated code still required item-by-item manual confirmation. In prototype stages or on non-critical pages, this type of result can reduce the time spent writing boilerplate code, provided that human review is performed.
3. Complex Interactions: Missed Items in List and Form Pages
When requirements involve multi-condition filtering, pagination linkage, and field dependencies, the differences in generated results increase markedly.
The main issue on the list page was missing filter items. The requirements document specified multi-dimensional filtering, pagination, and component linkage. The generated page retained the skeleton of the table, title, and action buttons, but several filter conditions were not implemented. Some filter controls were only rendered and were not connected to query logic. This issue appeared in multiple generations, but more samples are needed to judge its stability.
The issues on the form page were finer-grained. The generated form could run and had a complete structure, but the following rules were not implemented as specified in the document: show/hide dependencies between fields, async validation (for example, username uniqueness checks), and cross-field validation (for example, the start time must not be later than the end time). These rules were scattered across different sections of the document, making them more likely to be missed during extraction by the model.
Possible causes include information extraction from long documents, instruction-following capability, context window length, and decoding strategy. This article did not conduct ablation experiments, so it cannot determine which factor was the main cause. To locate the cause, one could split the requirements document into individual rules and input them one by one, or regenerate using only the relevant sections, and then compare changes in the miss rate.
4. Reproducible Comparison Table
The table below lists the requirement items to check, the check methods, and the pass criteria. Teams can use the same table to record the results of each generation.
| Page | Requirement item | Check method | Pass criteria |
|---|---|---|---|
| Login page | Carousel and basic layout | Open the preview URL in a browser and compare item by item against the design spec | Elements exist and are positioned correctly |
| Login page | Account and password validation | Submit empty values and malformed inputs separately | Corresponding messages are displayed and no request is sent |
| List page | Multi-dimensional filtering | Set filter conditions one by one and run queries | Query results match the conditions |
| List page | Pagination and filter linkage | Check the page number and total after changing filter conditions | Page number resets and total is correct |
| Form page | Field display dependency | Change the value of the trigger field | Dependent fields show or hide according to the rules |
| Form page | Async validation | Enter an existing value and wait for the API response | Validation failure message is displayed |
| Form page | Cross-field validation | Construct an out-of-range combination and submit | Submission is blocked with a message |
Reproduction steps: first record the environment information as described in Section 1, then generate code with the same prompt, and then execute the check items in the table in sequence. Failed items require screenshots and a reproduction path so that others can reproduce the same result by following the steps.
5. Time and Compute
Queuing and waiting often occurred during generation. From submitting the generation request to the preview URL becoming available, the elapsed time was sometimes long in this practice. Queuing may be related to server-side compute scheduling, the build environment, network conditions, or the number of concurrent requests. Without controlled variables, the specific main cause cannot be determined.
If teams need to use such tools in large-scale scenarios, they can evaluate the elastic compute, container platforms, and scheduling capabilities offered by general cloud platforms, using concurrency and response time as metrics for testing. This article discusses technical metrics only and does not involve any vendor selection recommendations.
6. Pre-Launch Risk Checks
AI-generated code cannot replace launch review. At a minimum, the following checks should be completed:
- Manual code review, with focus on request logic, state management, and error handling.
- Dependency vulnerability scanning, confirming that third-party packages introduced by generated code have no known high-severity vulnerabilities.
- Permission and data security testing, checking for unauthorized access and exposure of sensitive information in the front end.
- Regression cases for complex forms, covering every rule in the comparison table in this article.
- Compatibility testing, covering the browsers and devices actually used by the team.
Conclusion
Based on this sample, the model showed high completeness on standardized login pages and clear omissions on complex rules in list and form pages. Models can be used for prototyping and first drafts of non-critical pages, but complex business pages still require manual implementation and testing against requirements. Future evaluations should expand the sample size and fix the model version and prompt so that the real differences between tools can be compared.
