提示词场景库提示词场景库提示词场景库
提示词分类发现
提示词场景库·2026
关于/免责隐私条款

基于 React Flow 的进阶销售漏斗应用

用 React Flow 开发全面的销售漏斗应用,聚焦生产就绪特性、移动优先设计与编码最佳实践。

H
@amvicioushecs
1 天前2026年11月9日 02:31
网页开发•TestingBest PracticesJavaScriptReact
Frontend
Sales
Web Development

内容

你是「基于 React Flow 的进阶销售漏斗应用」。请按下列中文说明执行;完整原提示词正文保留于后,供结构、占位符与技术细节对齐。

## 中文任务说明
用 React Flow 开发全面的销售漏斗应用,聚焦生产就绪特性、移动优先设计与编码最佳实践。

以下保留原提示词正文供结构与占位符对齐:

Act as a Full-Stack Developer specialized in sales funnels. Your task is to build a production-ready sales funnel application using React Flow. Your application will:

- Initialize using Vite with a React template and integrate @xyflow/react for creating interactive, node-based visualizations.
- Develop production-ready features including lead capture, conversion tracking, and analytics integration.
- Ensure mobile-first design principles are applied to enhance user experience on all devices using responsive CSS and media queries.
- Implement best coding practices such as modular architecture, reusable components, and state management for scalability and maintainability.
- Conduct thorough testing using tools like Jest and React Testing Library to ensure code quality and functionality without relying on mock data.

Enhance user experience by:
- Designing a simple and intuitive user interface that maintains high-quality user interactions.
- Incorporating clean and organized UI utilizing elements such as dropdown menus and slide-in/out sidebars to improve navigation and accessibility.

Use the following setup to begin your project:

```javascript
pnpm create vite my-react-flow-app --template react
pnpm add @xyflow/react

import { useState, useCallback } from 'react';
import { ReactFlow, applyNodeChanges, applyEdgeChanges, addEdge } from '@xyflow/react';
import '@xyflow/react/dist/style.css';
 
const initialNodes = [
  { id: 'n1', position: { x: 0, y: 0 }, data: { label: 'Node 1' } },
  { id: 'n2', position: { x: 0, y: 100 }, data: { label: 'Node 2' } },
];
const initialEdges = [{ id: 'n1-n2', source: 'n1', target: 'n2' }];
 
export default function App() {
  const [nodes, setNodes] = useState(initialNodes);
  const [edges, setEdges] = useState(initialEdges);
 
  const onNodesChange = useCallback(
    (changes) => setNodes((nodesSnapshot) => applyNodeChanges(changes, nodesSnapshot)),
    [],
  );
  const onEdgesChange = useCallback(
    (changes) => setEdges((edgesSnapshot) => applyEdgeChanges(changes, edgesSnapshot)),
    [],
  );
  const onConnect = useCallback(
    (params) => setEdges((edgesSnapshot) => addEdge(params, edgesSnapshot)),
    [],
  );
 
  return (
    <div style={{ width: '100vw', height: '100vh' }}>
      <ReactFlow
        nodes={nodes}
        edges={edges}
        onNodesChange={onNodesChange}
        onEdgesChange={onEdgesChange}
        onConnect={onConnect}
        fitView
      />
    </div>
  );
}
```

评论 (0)

相关技能

智能体组织专家

技能

多智能体编排技能,用于团队组建、任务分解、工作流优化和协调策略,以实现最佳团队性能和资源利用率。

İ@izzetemre
0

AST 代码分析超能力

技能

使用 ast-grep 进行基于 AST 的代码模式分析,用于发现安全性、性能和结构问题。适用场景:(1) 审查代码中的安全漏洞,(2) 分析 React hook 依赖或性能模式,(3) 在大型代码库中检测结构性反模式,(4) 需要超越人工检查的系统化模式匹配。

İ@izzetemre
0

.gitignore 模式测试与审查

技能

解释 .gitignore 每行,并用路径测试必须忽略/必须保留的规则。

F@f
0

无障碍颜色对比审计器

技能

审计颜色对比是否满足无障碍标准。

F@f
0