वेब पर Cloud Storage का इस्तेमाल करके फ़ाइलें मिटाना
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
Cloud Storage पर फ़ाइलें अपलोड करने के बाद, उन्हें मिटाया भी जा सकता है.
फ़ाइल मिटाना
किसी फ़ाइल को मिटाने के लिए, सबसे पहले उस फ़ाइल का रेफ़रंस बनाएं. इसके बाद, उस रेफ़रंस पर delete() मेथड को कॉल करें. इससे, समस्या हल करने वाला Promise या Promise अस्वीकार होने पर गड़बड़ी का मैसेज मिलता है.
Web
import{getStorage,ref,deleteObject}from"firebase/storage";conststorage=getStorage();// Create a reference to the file to deleteconstdesertRef=ref(storage,'images/desert.jpg');// Delete the filedeleteObject(desertRef).then(()=>{// File deleted successfully}).catch((error)=>{// Uh-oh, an error occurred!});
// Create a reference to the file to deletevardesertRef=storageRef.child('images/desert.jpg');// Delete the filedesertRef.delete().then(()=>{// File deleted successfully}).catch((error)=>{// Uh-oh, an error occurred!});
फ़ाइल मिटाने पर गड़बड़ियां होने की कई वजहें हो सकती हैं. जैसे, फ़ाइल मौजूद न होना या उपयोगकर्ता के पास फ़ाइल मिटाने की अनुमति न होना. गड़बड़ियों के बारे में ज़्यादा जानकारी पाने के लिए, दस्तावेज़ों के गड़बड़ियों को मैनेज करें सेक्शन पर जाएं.
[[["समझने में आसान है","easyToUnderstand","thumb-up"],["मेरी समस्या हल हो गई","solvedMyProblem","thumb-up"],["अन्य","otherUp","thumb-up"]],[["वह जानकारी मौजूद नहीं है जो मुझे चाहिए","missingTheInformationINeed","thumb-down"],["बहुत मुश्किल है / बहुत सारे चरण हैं","tooComplicatedTooManySteps","thumb-down"],["पुराना","outOfDate","thumb-down"],["अनुवाद से जुड़ी समस्या","translationIssue","thumb-down"],["सैंपल / कोड से जुड़ी समस्या","samplesCodeIssue","thumb-down"],["अन्य","otherDown","thumb-down"]],["आखिरी बार 2025-03-21 (UTC) को अपडेट किया गया."],[],[]]