3
3

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.

vue.js構築

3
Last updated at Posted at 2017-09-18

macにvueをインストールします。

homebrewでnodeを落としてきます。

$brew install node
==> Installing dependencies for node: icu4c
==> Installing node dependency: icu4c
==> Downloading https://homebrew.bintray.com/bottles/icu4c-59.1.el_capitan.bottle.tar.gz
######################################################################## 100.0%
==> Pouring icu4c-59.1.el_capitan.bottle.tar.gz
==> Caveats
This formula is keg-only, which means it was not symlinked into /usr/local,
because macOS provides libicucore.dylib (but nothing else).

If you need to have this software first in your PATH run:
  echo 'export PATH="/usr/local/opt/icu4c/bin:$PATH"' >> ~/.bash_profile
  echo 'export PATH="/usr/local/opt/icu4c/sbin:$PATH"' >> ~/.bash_profile

For compilers to find this software you may need to set:
    LDFLAGS:  -L/usr/local/opt/icu4c/lib
    CPPFLAGS: -I/usr/local/opt/icu4c/include

==> Summary
🍺  /usr/local/Cellar/icu4c/59.1: 246 files, 65.4MB
==> Installing node
==> Downloading https://homebrew.bintray.com/bottles/node-8.5.0.el_capitan.bottle.tar.gz
######################################################################## 100.0%
==> Pouring node-8.5.0.el_capitan.bottle.tar.gz
==> Caveats
Bash completion has been installed to:
  /usr/local/etc/bash_completion.d
==> Summary
🍺  /usr/local/Cellar/node/8.5.0: 4,152 files, 48MB

$node -v
v8.5.0

vue.jsをインストール

# vueインストール
$npm install vue
+ vue@2.4.4

# vue-cliインストール
$npm install --global vue-cli

プロジェクトの生成

E2EはいらないのでそれだけNoにしてます

$vue init webpack front

? Project name front
? Project description A Vue.js project
? Author takumi 
? Vue build standalone
? Install vue-router? Yes
? Use ESLint to lint your code? Yes
? Pick an ESLint preset Standard
? Setup unit tests with Karma + Mocha? Yes
? Setup e2e tests with Nightwatch? No

vue-cli · Generated "front".

必要パッケージをインストール

$cd front
$npm install

実行してみる

$npm run dev

スクリーンショット 2017-09-18 14.54.25.png

3
3
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
3
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?