MCPcopy Create free account
hub / github.com/TanStack/devtools / UpgradeRowActions

Function UpgradeRowActions

examples/react/basic/src/package-json-panel.tsx:159–188  ·  view source on GitHub ↗
({ name }: { name: string })

Source from the content-addressed store, hash-verified

157 }
158
159 const UpgradeRowActions = ({ name }: { name: string }) => {
160 const info = outdatedDeps[name] as
161 | {
162 current: string
163 wanted: string
164 latest: string
165 type?: 'dependencies' | 'devDependencies'
166 }
167 | undefined
168 if (!info) return null
169 return (
170 <div style={{ display: 'flex', gap: 6 }}>
171 {btn('Wanted', () =>
172 (devtoolsEventClient as any).emit('upgrade-dependency', {
173 name,
174 target: info.wanted,
175 } as any),
176 )}
177 {btn(
178 'Latest',
179 () =>
180 (devtoolsEventClient as any).emit('upgrade-dependency', {
181 name,
182 target: info.latest,
183 } as any),
184 'ghost',
185 )}
186 </div>
187 )
188 }
189
190 const makeLists = (names?: Array<string>) => {
191 const entries = Object.entries(outdatedDeps).filter(

Callers

nothing calls this directly

Calls 2

btnFunction · 0.70
emitMethod · 0.45

Tested by

no test coverage detected