MCPcopy
hub / github.com/spicetify/cli / corsProxyTemplate

Function corsProxyTemplate

CustomApps/lyrics-plus/Settings.js:496–510  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

494};
495
496const corsProxyTemplate = () => {
497 const [proxyValue, setProxyValue] = react.useState(localStorage.getItem("spicetify:corsProxyTemplate") || "https://cors-proxy.spicetify.app/{url}");
498
499 return react.createElement("input", {
500 placeholder: "CORS Proxy Template",
501 value: proxyValue,
502 onChange: (event) => {
503 const value = event.target.value;
504 setProxyValue(value);
505
506 if (value === "" || !value) return localStorage.removeItem("spicetify:corsProxyTemplate");
507 localStorage.setItem("spicetify:corsProxyTemplate", value);
508 },
509 });
510};
511
512const OptionList = ({ type, items, onChange }) => {
513 const [itemList, setItemList] = useState(items);

Callers

nothing calls this directly

Calls 1

removeItemMethod · 0.80

Tested by

no test coverage detected