Skip to content
| Marketplace
Sign in
Visual Studio Code>Snippets>Tag Pair CloserNew to Visual Studio Code? Get it now.
Tag Pair Closer

Tag Pair Closer

cheat-snippet

| (0) | Free
Automatically close paired HTML, XML, and JSX tags.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Tag Pair Closer

Extension hỗ trợ tự động đóng thẻ và cung cấp bộ snippet tiện ích cho bài thực hành FoodApp.

Danh sách Snippet theo từng câu

Câu 1: Cấu trúc Store, Types & Navigation

  • cau1src-type : Khai báo kiểu Food, CartItem trong src/types.ts
  • cau1src-store-cartSlice : Tạo khung cartSlice.ts
  • cau1src-store-favoritesSlice : Tạo khung avoritesSlice.ts
  • cau1src-store-index : Cấu hình Redux store trong src/store/index.ts
  • cau1src-navigation-types : Khai báo kiểu Navigation trong src/navigation/types.ts
  • cau1src-screens-MenuScreen : Tạo màn hình tạm MenuScreen.tsx
  • cau1src-screens-CartScreen : Tạo màn hình tạm CartScreen.tsx
  • cau1src-screens-AccountScreen : Tạo màn hình tạm AccountScreen.tsx
  • cau1src-screens-FoodDetailScreen : Tạo màn hình tạm FoodDetailScreen.tsx
  • cau1src-screens-FavoritesScreen : Tạo màn hình tạm FavoritesScreen.tsx
  • cau1src-screens-tam : Tạo cả 5 màn hình tạm cùng lúc
  • cau1src-navigation-AppNavigator : Cấu hình Navigation Tabs và Stack
  • cau1App : Bọc Provider trong App.tsx

Câu 2: Thực đơn (Menu & Detail)

  • cau2src-utils-format : Hàm ormatVND
  • cau2src-api-foods : API etchFoods và etchFoodById
  • cau2src-components-FoodCard : Component FoodCard.tsx
  • cau2src-screens-MenuScreen : Màn hình Thực đơn MenuScreen.tsx
  • cau2src-screens-FoodDetailScreen : Màn hình Chi tiết FoodDetailScreen.tsx

Câu 3: Giỏ hàng (Cart Slice, Row, CartScreen & Badge)

  • cau3src-store-cartSlice : Hoàn thiện cartSlice.ts (addToCart, setQuantity, removeFromCart, clearCart, hydrateCart)
  • cau3src-screens-FoodDetailScreen : Nút 'Thêm vào giỏ' trong FoodDetailScreen.tsx
  • cau3src-components-CartItemRow : Component CartItemRow.tsx
  • cau3src-screens-CartScreen : Màn hình Giỏ hàng CartScreen.tsx
  • cau3src-navigation-AppNavigator : Cấu hình Badge giỏ hàng trong AppNavigator.tsx

Câu 4: Lưu bằng AsyncStorage

  • cau4src-hooks-usePersist : Hook chung usePersist.ts
  • cau4App : Bọc Root trong App.tsx chờ nạp Storage
  • cau4src-store-favoritesSlice : Action hydrateFavorites trong avoritesSlice.ts

Câu 5: Yêu thích (Favorites)

  • cau5src-store-favoritesSlice : Action oggleFavorite trong avoritesSlice.ts
  • cau5src-components-FavoriteButton : Component nút FavoriteButton.tsx
  • cau5src-components-FoodCard : Gắn FavoriteButton vào FoodCard.tsx
  • cau5src-screens-FoodDetailScreen : Gắn FavoriteButton vào FoodDetailScreen.tsx
  • cau5src-screens-AccountScreen : Cập nhật AccountScreen.tsx
  • cau5src-screens-FavoritesScreen : Màn hình danh sách FavoritesScreen.tsx

Câu 6: Debounce Tăng/Giảm (350ms)

  • cau6src-hooks-useDebouncedQuantities : Hook useDebouncedQuantities.ts
  • cau6src-screens-CartScreen : Áp dụng debounce vào CartScreen.tsx

Câu 7: Mã giảm giá (Coupons API)

  • cau7src-type : Khai báo type Coupon trong src/types.ts
  • cau7src-screens-CartScreen : Thêm tính năng áp dụng mã giảm giá vào CartScreen.tsx

Dự phòng

  • cheat : Bung toàn bộ mã nguồn của cả bài tập (cheat_V2.txt)
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft