You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
How can I declare that method show can accept string union from ASSETS['js'] keys ('foo-script'|'bar-script')?
I'm tired to use @param key-of<ASSETS['js']> $key but got error [InvalidDocblock](https://psalm.dev/008) - 18:15 - Unrecognised template param 'js' in docblock for AdminAssets::show
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I have the following code
How can I declare that method
show
can accept string union fromASSETS['js']
keys ('foo-script'|'bar-script'
)?I'm tired to use
@param key-of<ASSETS['js']> $key
but got error[InvalidDocblock](https://psalm.dev/008) - 18:15 - Unrecognised template param 'js' in docblock for AdminAssets::show
Beta Was this translation helpful? Give feedback.
All reactions