I want to change file loading process, I'm using vue.js in laravel 8 i want to load app.js from vue component first then whole project - vue.js

Im using vue.js with laravel and I want to load app.js from vue component first then whole project. Where i can find the auto-load setup where i can change the priority of file loading.

Related

Nuxt 3 files not visible in the directory structure

I recently started learning NuxtJs and create a nuxt app using the nuxt3 template. The code i used to generate the starter project is
npx nuxi init nuxt-app
However the the terminal shows that the app has been created and the dev server also starts displaying the Nuxt3 welcome page. But when i load the directory in vs code the folders like pages,store and components are not visible as seen in the screenshot below .
You are importing <NuxtWelcome /> component from node_modules folder. Delete it and replace with <NuxtPages/>. Create your own components in folder pages. Nuxt 3 imports components by itself, so you don't see them in <script> tag. <NuxtPages /> will do the magic with components in page folder. For example, Index.vue component you will see in / home page and About.vue in /about.
This behavior is a year old already: Some of the directories are missing when I'm trying to create a new Nuxt js project
The idea is to have something minimal where you could then add all the needed directories.
Benefit being that if you don't use any pages, the final bundle will be smaller (no need to being in Vue router for example). Same for the store (no need to import Vuex/Pinia), server part etc...
It's less of a "you have everything from the start" and more of a "pick what you like the most"!

Ionic Vue and AR.js

So i have initiated a project with Ionic Vue and I would like to know how can i implement AR.js into it. I have tried creating a simple html file containing the code of importing and then put an iframe into the ion-content of the Home.vue file but nothing

How to import external Vue components from .js file via web URL?

I want to be able to use Vue components distributed over CDN without the need to npm install them - in my single-file Vue components.
I do not understand how to import them by URL to compiled component.
Example of components I want to import is
https://unpkg.com/vueperslides (from https://antoniandre.github.io/vueper-slides/#installation)
As I understand there is a way to load JS file in mounted() hook or something, but I don't understand how to import exports from it after.
Answers I tried include
https://markus.oberlehner.net/blog/distributed-vue-applications-loading-components-via-http/
How to add external JS scripts to VueJS Components
and many others.
I am building a web app using Quasar Framowrk on Vue.js v2

Using Laravel config file data inside vue component

I am developing a web app using laravel and vue . Now i want to use laravel config file data like app name inside vue component . How do i suppose to do that ?
We can pass config data as props to vue component.

Nightwatch.js E2E - can it test Vue.js Single File Components Loaded via Vue Router

Our case is:
Vue.js
Vuex
Vue Router
Single File Components
Vue Router repo has examples for Nightwatch.js E2E testing, but not for single file components.
When we tried, the result of tests of loading components, with
.assert.elementPresent
where not consistent. We tested clicking a router-link and looked for loading the corresponding single file component (SFC). That is, the current component was replaced on the page by the loaded component.
Our navigation is through a Vue Material drawer drawer. But we believe this is not ann essential element. But we may be wrong here.
Was someone able to get consistent results of tests of loading of such components?