fix(example): Header showing an empty option

This commit is contained in:
Braks
2021-08-08 23:05:10 +02:00
parent 3cd0693b93
commit 15f968c607
+7 -5
View File
@@ -16,11 +16,13 @@ const Header = defineComponent({
Revue Flow Dev Revue Flow Dev
</a> </a>
<select v-model={route.path} onChange={onChange}> <select v-model={route.path} onChange={onChange}>
{routes.map((route) => ( {routes.map((route) =>
<option value={route.path} key={route.path}> route.path !== '/' ? (
{route.path === '/' ? 'basic' : route.path.substr(1, route.path.length)} <option value={route.path} key={route.path}>
</option> {route.path.substr(1, route.path.length)}
))} </option>
) : null
)}
</select> </select>
</header> </header>
); );