How does Tailwind CSS's utility-first approach differ from traditional CSS frameworks that offer pre-designed components?
4 phương ánCó giải thích
Các phương án trả lời
Chọn một phương ánLời giảiChọn phương án để mở
Đáp án đúng: "Tailwind CSS provides low-level utility classes for styling, while traditional frameworks offer pre-built components with limited customization.". Tailwind theo hướng utility-first: mỗi lớp là một viên gạch định kiểu cấp thấp như khoảng đệm, màu nền, cỡ chữ, bố cục flex, ta ghép chúng trực tiếp trên phần tử để tạo giao diện riêng; còn Bootstrap hay framework truyền thống đưa ra component hoàn chỉnh như card, navbar với diện mạo định sẵn, muốn khác đi phải ghi đè CSS. Phát biểu "Tailwind CSS provides a set of pre-designed components that can be customized with utility classes" sai vì nó đảo ngược hai bên: Tailwind lõi không có component dựng sẵn và chính nó mới là bên linh hoạt hơn. Phát biểu "relies on JavaScript to generate styles dynamically" sai vì Tailwind quét mã lúc build và sinh ra tệp CSS tĩnh, không tạo kiểu bằng JavaScript lúc chạy. Phát biểu "Tailwind CSS is primarily used for server-side rendering" sai vì Tailwind chỉ là CSS, dùng được với mọi cách render, không gắn với SSR hay CSR.
Cùng phần 3
Which Bootstrap class is commonly used to create a responsive navigation bar?Có lời giảiCâu hỏiFill in the blank in this Bootstrap CSS code to apply a primary button style using React-Bootstrap: import { Button } from 'react-bootstrap'; <Button _______="primary">Click me</Button>Có lời giảiCâu hỏiWhich Bootstrap class provides a fluid container that adapts to all breakpoints?Có lời giảiCâu hỏiCả 36 câu của chủ đề36 câu
Xuất hiện trong 1 bộ đề
Đi tiếp từ đây