player
player copied to clipboard
`:key-shortcuts="{ toggleFullscreen: null }"` throws JSON.parse error
Current Behavior:
In my vue application when I define a media player with:
<media-player :key-shortcuts="{ toggleFullscreen: null }" />
It throws a JSON.parse error.
Expected Behavior:
Should it interpret the object as it should?
Steps To Reproduce:
<media-player :key-shortcuts="{ toggleFullscreen: null }" />
Environment:
- Framework: Vue
- Meta Framework: Nuxt
- Node: 22.0.0
Workaround:
I am working around this issue by stringifying the object. But that feels fishy.
<media-player
:key-shortcuts="JSON.stringify({
toggleFullscreen: null,
}) as any"
></media-player>