MCPcopy Create free account
hub / github.com/codeaashu/claude-code / MarketplaceList

Function MarketplaceList

src/commands/plugin/PluginSettings.tsx:31–74  ·  view source on GitHub ↗
(t0)

Source from the content-addressed store, hash-verified

29import { ValidatePlugin } from './ValidatePlugin.js';
30type TabId = 'discover' | 'installed' | 'marketplaces' | 'errors';
31function MarketplaceList(t0) {
32 const $ = _c(4);
33 const {
34 onComplete
35 } = t0;
36 let t1;
37 let t2;
38 if ($[0] !== onComplete) {
39 t1 = () => {
40 const loadList = async function loadList() {
41 ;
42 try {
43 const config = await loadKnownMarketplacesConfig();
44 const names = Object.keys(config);
45 if (names.length === 0) {
46 onComplete("No marketplaces configured");
47 } else {
48 onComplete(`Configured marketplaces:\n${names.map(_temp).join("\n")}`);
49 }
50 } catch (t3) {
51 const err = t3;
52 onComplete(`Error loading marketplaces: ${errorMessage(err)}`);
53 }
54 };
55 loadList();
56 };
57 t2 = [onComplete];
58 $[0] = onComplete;
59 $[1] = t1;
60 $[2] = t2;
61 } else {
62 t1 = $[1];
63 t2 = $[2];
64 }
65 useEffect(t1, t2);
66 let t3;
67 if ($[3] === Symbol.for("react.memo_cache_sentinel")) {
68 t3 = <Text>Loading marketplaces...</Text>;
69 $[3] = t3;
70 } else {
71 t3 = $[3];
72 }
73 return t3;
74}
75function _temp(n) {
76 return ` • ${n}`;
77}

Callers

nothing calls this directly

Calls 1

loadListFunction · 0.85

Tested by

no test coverage detected