Published on: 23 February, 2018

How to publish or deploy Vue.js app?

Posted by andy | 146 views 0 likes 0 favourites 0 comments
Tumblr Digg Google Plus

Once you have completed the development phase of your Vue.js app, you want to start deploying or publishing your Vue.js app. To deploy it is pretty simple, what you have to do is to deploy using the Node.js command prompt. Note: this only applies if you are using the CLI mode without using the Vue.js script tag directly.

To start deploying you can run the following command.

npm run build

This is a sample performing a deployment for Vue.js app. If you see the screenshot below is based on the first example in Vue.js my-project tutorial.

How does the deployment work? If you see in your project folder, you will notice there is a folder called build. Inside the build folder, there is a build.js file where all the command and build requirement are specified in this setting file. In this example, I used the default webpack specified in the Vue.js default CLI project.

Where are the published Vue.js files?

Once the publish process has completed, you can find all the files under the dist folder. Just copy the files inside the dist folder and deploy it on your server.


There are no comments available.

Write Comment
0 characters entered. Maximum characters allowed are 1000 characters.
Share your article with us and add your own google adsense account to earn extra money. Plus, you can promote a link back to your site.
Related Articles
Published on: 10 March, 2018
In this tutorial, you will learn how to create a custom form validation in Vue.js. I will create a simple validation using the help of JQuery library for the event attachment and DOM query. If you do not want to use JQuery, feel free to change it to native Javascript. The reason why I use JQuery library is to save time in the development phase. Let's get started with the concept.
Published on: 23 February, 2018
To turn off the eslint feature in your Vue.js app is pretty simple. What you need to do is to go to the root folder and look for the config folder in your Vue.js project. There will be a file named index.js and look for the wording useEslint option.
Published on: 08 February, 2018
In this tutorial, you will learn on how to create custom directives in Vue.js. We will create two custom directives that will perform a check for an input that will accept numbers only and another custom directive that will accept whole numbers only. We will implement blur event on the input and if the user has entered wrong input. It will return 0 as default value.