0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-01-08 05:22:40 +00:00

remove prop drilling

This commit is contained in:
Víctor Losada Hernández
2025-07-18 16:39:00 +02:00
parent e0bba53df1
commit d5645083f3
5 changed files with 4 additions and 8 deletions

View File

@@ -39,8 +39,7 @@ const Homebrew = (props)=>{
lang : ''
},
userThemes,
brews,
isOwner,
brews
} = props;
global.account = account;
@@ -53,7 +52,7 @@ const Homebrew = (props)=>{
<Router location={url}>
<div className='homebrew'>
<Routes>
<Route path='/edit/:id' element={<WithRoute el={EditPage} isOwner={isOwner} brew={brew} userThemes={userThemes}/>} />
<Route path='/edit/:id' element={<WithRoute el={EditPage} brew={brew} userThemes={userThemes}/>} />
<Route path='/share/:id' element={<WithRoute el={SharePage} brew={brew} />} />
<Route path='/new/:id' element={<WithRoute el={NewPage} brew={brew} userThemes={userThemes}/>} />
<Route path='/new' element={<WithRoute el={NewPage} userThemes={userThemes}/> } />