Category : nuxt.js

I have a ListProjects.vue inside components folder. ul li(v-for="project in projects", :key="project.title") a(:href="project.url") {{ project.title }} I also have projects.yaml in content folder list: – title: Project 1 url: https://www.project1.com – title: Project 2 url: https://www.project2.com If I fetch the content of projects.yaml on my index.vue page and pass as props to ListProjects.vue, hot reload ..

Read more

Here is my config: auth: { plugins: [‘~/plugins/auth.js’], strategies: { local: { scheme: ‘refresh’, token: { property: ‘jwtToken’, }, refreshToken: { property: ‘refreshToken’, data: ‘refreshToken’, }, user: false, endpoints: { login: { url: ‘/api/account/authenticate’, method: ‘post’ }, logout: { url: ‘/api/account/logout’, method: ‘post’ }, mPassLogout: { url: ‘/api/account/init-mpass-logout’, method: ‘get’ }, refresh: { url: ‘/api/account/refresh-token’, ..

Read more

cant access the elements of the file array const p_page = postP.new_pages; const p_page_o = postP.new_pages_order; const p_page_o_len = p_page_o.length; if (p_page_o_len > 0) { for (let i = 0; i < p_page_o_len; i++) { console.log(p_page); //Returns array with files inside it console.log(p_page[0]); //returns undefined console.log(p_page[i]); //returns undefined formData.append("pages[]", p_page[i]); formData.append("pages_order[]", p_page_o[i]); } } And ..

Read more

I want to pass a value parameters in my URL, my mounted is like this mounted () { this.$router.push({ path: ‘/activatewithphone’, query: { serial: this.$route.params.serial, machine: this.$route.params.machine } }) }, My computed computed: { serial () { return this.$route.query.serial }, machine () { return this.$route.query.email } }, I get serial and machine value like this ..

Read more

I want to pass a value parameters in my URL, my mounted is like this mounted () { this.$router.push({ path: ‘/activatewithphone’, query: { serial: this.$route.params.serial, machine: this.$route.params.machine } }) }, My computed computed: { serial () { return this.$route.query.serial }, machine () { return this.$route.query.machine } }, I get serial and machine value like this ..

Read more

For Example I have this mounted () { this.$router.push({ path: ‘/activatewithphone’, query: { serial: this.$route.params.serial, machine: this.$route.params.machine } }) }, This means whenever a user visits a URL like this http://example.com/activate?serial=sddsdsds&machine=sdsdsd The user will not be shown a 404 page. The value of serial and machine is dynamic and can be anything. My question is ..

Read more

I try to install @headlessui/vue in my nuxt project. When I try to use it like: <template> <Menu> <MenuItems> <MenuItem>Item</MenuItem> </MenuItems> </Menu> </template> <script lang="ts"> import Vue from ‘vue’ import { Menu, MenuButton, MenuItems, MenuItem } from ‘@headlessui/vue’ export default Vue.extend({ components: { Menu, MenuButton, MenuItems, MenuItem }, data () { return { isScrolling: false ..

Read more