provide environment variable to use vtt options

This commit is contained in:
Jonathan Baecker 2024-09-27 11:55:01 +02:00
parent 7bfaa4a2d0
commit 5ee8cd3cfb
3 changed files with 18 additions and 0 deletions

View File

@ -107,3 +107,13 @@ npm run preview
``` ```
Check out the [deployment documentation](https://nuxt.com/docs/getting-started/deployment) for more information. 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.

View File

@ -19,6 +19,7 @@
v-if=" v-if="
name.toString() !== 'startInSec' && name.toString() !== 'startInSec' &&
name.toString() !== 'lengthInSec' && name.toString() !== 'lengthInSec' &&
!(name.startsWith('vtt_') && !config.public.buildExperimental) &&
!(name.toString() === 'path' && key.toString() === 'storage') !(name.toString() === 'path' && key.toString() === 'storage')
" "
> >
@ -93,6 +94,7 @@
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
const config = useRuntimeConfig()
const { t } = useI18n() const { t } = useI18n()
const authStore = useAuth() const authStore = useAuth()

View File

@ -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**'], ignore: ['**/public/tv-media**', '**/public/Videos**', '**/public/live**', '**/public/home**'],
ssr: false, ssr: false,