Tìm nạp là một API mới giúp việc tìm nạp tài nguyên từ xa trở nên dễ dàng hơn nhiều. Giống như XMLHttpRequest, Bạn có thể sử dụng Tìm nạp để thực hiện các yêu cầu giống nhau về nguồn gốc hoặc yêu cầu trên nhiều miền. Tìm nạp sử dụng API rõ ràng hơn, mạnh mẽ hơn, phân tách yêu cầu khỏi phản hồi và sử dụng lời hứa trả về phản hồi.
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mẫu mã lập trình được cấp phép theo Giấy phép Apache 2.0. Để biết thông tin chi tiết, vui lòng tham khảo Chính sách trang web của Google Developers. Java là nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết với Oracle.
Cập nhật lần gần đây nhất: 2024-08-09 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2024-08-09 UTC."],[[["Fetch API simplifies fetching remote resources, offering a more streamlined approach than XMLHttpRequest."],["It supports both same-origin and cross-domain requests for versatile resource retrieval."],["Fetch API provides a clear separation between request and response for enhanced code organization."],["It leverages promises for efficient asynchronous handling of responses, improving code readability and performance."]]],["Fetch API simplifies fetching remote resources, handling both same-origin and cross-domain requests. It offers a refined interface compared to XMLHttpRequest, distinguishing the request from the response. Crucially, Fetch utilizes promises to deliver the response, providing a more structured and efficient method for managing asynchronous operations. Its improved design aims to streamline the process of data retrieval from remote sources.\n"]]