2
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

GitHub Pages に Vue.js を Hosting する

Posted at

GitHub Pages は静的ページや SPA を無料でサクッと公開したい時に便利ですね。
でも、dist/ ではなく docs/ に成果物を配置する必要があります。

やり方

プロジェクト直下に vue.config.js を作成します。

vue.config.js
module.exports = {
  outputDir: './docs',
}

ビルドすると docs/ 以下にビルドしてくれます。

$ yarn build

あとは master に $ git commit して $ git push すれば反映されるはずです。

2
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?