关于 NextJS 基础问题 或者说 React 的请教

122 天前
ugpu  ugpu

多年来一直从事后端开发, 前段时间开始学习 Next.JS 全栈框架. 产生了一些疑问 主要是针对前端问题.

问题如下: 前端开发者是如何快速写出优雅的界面. 依赖 CSS ?

前端开发者是如何快速修改 或者 从 0-1 开发的? 大多是去找模板复制 二次修改吗? 那么这类模板网站大家用的多的是哪些 可以共享吗?

如下 CSS : cva( 'inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50', { variants: { variant: { default: 'bg-primary text-primary-foreground hover:bg-primary/90', destructive: 'bg-destructive text-destructive-foreground hover:bg-destructive/90', outline: 'border border-input bg-background hover:bg-accent hover:text-accent-foreground', secondary: 'bg-secondary text-secondary-foreground hover:bg-secondary/80', ghost: 'hover:bg-accent hover:text-accent-foreground', link: 'text-primary underline-offset-4 hover:underline', }, size: { default: 'h-10 px-4 py-2', sm: 'h-9 rounded-md px-3', lg: 'h-11 rounded-md px-8', icon: 'size-10', }, }, defaultVariants: { variant: 'default', size: 'default', }, }, )

753 次点击
所在节点   问与答  问与答
5 条回复
Yukiteru
Yukiteru
122 天前
前端和 UI 是两套活,多数时候都是 UI 设计好前端来实现。个人项目的话就到处“借鉴”呗,不过你想的话也可以自学 UI 设计
ugpu
ugpu
122 天前
@Yukiteru 其实我是看很多项目依赖 CSS 极少的 UI 也能快速出活 做出精美界面 产生了疑问.
看来我得找个网站抄一抄 熟能生巧了
FondantCN
FondantCN
122 天前
借鉴同行和去 codepen.io 逛逛
liaohongxing
liaohongxing
122 天前
要想好看,都是抄出来的,抄多了就有感觉了。色值就来了,自己就能出界面了。
chiaf
chiaf
122 天前
找免费的模版吧。之前 tailwindcss 上面的模版还都是免费的,现在收费了。之前学 lareval 的时候,看的视频中教前端部分作者就是在 tailwind 上找的免费的,当我去找的时候,大部分都收费了🌚

这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。

https://www.v2ex.com/t/1081502

V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。

V2EX is a community of developers, designers and creative people.

© 2021 V2EX