mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-17 18:11:20 -08:00
build(site): [SITE-07] preserve exact Stack Overflow revision and attribution
This commit is contained in:
1 parent
3136eb2402
commit
0503fe8aa8
30 files changed
+1941
-27
No files matched your search
@@ -0,0 +1,14 @@
|
||||
const customStringify = function (v) {
|
||||
const cache = new Set();
|
||||
return JSON.stringify(v, function (key, value) {
|
||||
if (typeof value === 'object' && value !== null) {
|
||||
if (cache.has(value)) {
|
||||
// Circular reference found, discard key
|
||||
return;
|
||||
}
|
||||
// Store value in our set
|
||||
cache.add(value);
|
||||
}
|
||||
return value;
|
||||
});
|
||||
};
|
||||
Reference in new issue
Block a user