mirror of
https://github.com/henrywhitaker3/Speedtest-Tracker.git
synced 2025-12-25 06:49:15 +01:00
348 B
348 B
toJson()
The toJson method converts the collection into JSON string:
const collection = collect({
id: 384,
name: 'Rayquaza',
gender: 'NA',
});
const json = collection.toJson();
// {"id": 384, "name": "Rayquaza", "gender": "NA"}