Skip to content

Commit

Permalink
provide environment variable to use vtt options
Browse files Browse the repository at this point in the history
  • Loading branch information
jb-alvarado committed Sep 27, 2024
1 parent 7bfaa4a commit 5ee8cd3
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 0 deletions.
10 changes: 10 additions & 0 deletions docs/developer.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,3 +107,13 @@ npm run preview
```

Check out the [deployment documentation](https://nuxt.com/docs/getting-started/deployment) for more information.

### Experimental Frontend Features

To use experimental frontend features, add `NUXT_BUILD_EXPERIMENTAL=true` tu run and build command, like:

```
NUXT_BUILD_EXPERIMENTAL=true npm run dev
```

**Note:** This function is only for developers and testers who can do without support.
2 changes: 2 additions & 0 deletions frontend/components/ConfigPlayout.vue
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
v-if="
name.toString() !== 'startInSec' &&
name.toString() !== 'lengthInSec' &&
!(name.startsWith('vtt_') && !config.public.buildExperimental) &&
!(name.toString() === 'path' && key.toString() === 'storage')
"
>
Expand Down Expand Up @@ -93,6 +94,7 @@
</template>

<script setup lang="ts">
const config = useRuntimeConfig()
const { t } = useI18n()
const authStore = useAuth()
Expand Down
6 changes: 6 additions & 0 deletions frontend/nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ export default defineNuxtConfig({
},
},

runtimeConfig: {
public: {
buildExperimental: process.env.NUXT_BUILD_EXPERIMENTAL,
},
},

ignore: ['**/public/tv-media**', '**/public/Videos**', '**/public/live**', '**/public/home**'],
ssr: false,

Expand Down

0 comments on commit 5ee8cd3

Please sign in to comment.