DEV Community

Bryan
Bryan

Posted on • Originally published at devlogbook.com

5 1

Deploy Vite VueJs App to DigitalOcean App Platform with vue router working

Resources

  1. Choose code source location
  2. Click the pencil to edit the app as show in the image below Edit app
  3. Edit Resource Type from Web Service to Static Site

Environment Variables

Optional Add env variables for the app

Info

Optional Update App info

Review

Review and Create Resources

Edit App Spec

Note: Required, since it's a SPA, the routes created with Vue Router will not work

  1. Go to the app settings in Digital Ocean App settings in Digital Ocean
  2. Scroll down to App Spec and click Edit App spec
  3. Add index_document: index.html right below the last line with the same indentation as the one before and Save ```yaml

Check the indentation

  routes:
  - path: /
  source_dir: /
  index_document: index.html
Enter fullscreen mode Exit fullscreen mode
Enter fullscreen mode Exit fullscreen mode

Image of Datadog

The Essential Toolkit for Front-end Developers

Take a user-centric approach to front-end monitoring that evolves alongside increasingly complex frameworks and single-page applications.

Get The Kit

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay