Deploy Vue to GitHub pages-the easy way!

Setting Up Our Project

vue init webpack git-deploy-template
cd git-deploy-template

Add Our Deployment Script

npm install --save-dev push-dir
npm run build; push-dir --dir=dist --branch=gh-pages --cleanup

Fixing Our Base URL

Plot Twist

vue init codetheorist/webpack

--

--

--

PHP & JavaScript focused developer, mainly using Laravel & Vue.JS, I develop most projects under the alias @codetheorist

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Send, Read and Delete SMS in React Native

Send, Read and Delete SMS in React Native

Porting a Multiple-Page Application to React: A Piecemeal Approach with React Router 4

Getting Started with the Blazor Bullet Chart

A Summary of 20 Main and Modern Array Methods in JavaScript

Vue Router — The Missing Manual

Meet Vuh, our reusable design system!

Automating Coding Guidelines in Angular (VS Code)

What is React Native App Development? Is There any Future of It?

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Alex Scott

Alex Scott

PHP & JavaScript focused developer, mainly using Laravel & Vue.JS, I develop most projects under the alias @codetheorist

More from Medium

Vue, Vuetify.js & dark mode

Vuetify Margin and Padding: How to Use Vuetify Spacing Classes

[2022] How to use subdirectories for hosting in Vue CLI’s Router (for Blank page problem)

Firebase Auth Using Vue.js