Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save ChemprenX/b762c90223cd56014c4a6be6a8a8832f to your computer and use it in GitHub Desktop.

Select an option

Save ChemprenX/b762c90223cd56014c4a6be6a8a8832f to your computer and use it in GitHub Desktop.

Revisions

  1. @ratiw ratiw revised this gist Aug 11, 2015. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions Setting up Laravel & Vuejs.md
    Original file line number Diff line number Diff line change
    @@ -23,10 +23,10 @@
    - Install vue.js using `npm install vue --save`
    - Open `app.js` and type the following

    ---
    ```javascript
    var Vue = require('vue');

    new Vue({
    el: '#app'
    });
    ---
    ```
  2. @ratiw ratiw revised this gist Aug 11, 2015. 1 changed file with 11 additions and 7 deletions.
    18 changes: 11 additions & 7 deletions Setting up Laravel & Vuejs.md
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,6 @@
    - Setup Laravel app
    - Setup vue.js inside laravel app
    # Steps
    1. Setup Laravel app
    2. Setup vue.js inside laravel app
    ---------------------------------

    ## Setup Laravel app
    @@ -21,8 +22,11 @@
    - Install Elixer with `npm install`
    - Install vue.js using `npm install vue --save`
    - Open `app.js` and type the following
    > var Vue = require('vue');
    >
    > new Vue({
    > el: '#app'
    > });

    ---
    var Vue = require('vue');

    new Vue({
    el: '#app'
    });
    ---
  3. @ratiw ratiw created this gist Aug 11, 2015.
    28 changes: 28 additions & 0 deletions Setting up Laravel & Vuejs.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,28 @@
    - Setup Laravel app
    - Setup vue.js inside laravel app
    ---------------------------------

    ## Setup Laravel app
    - New Laravel app
    - Rename `.env.example` to `.env`
    - Config `config/database.php` to MySQL or SQLite
    - For SQLite, run `touch storage/database.sqlite` to create sqlite database
    - (optional) Create necessary Models and migrations using `art make:model -m`
    - (optional) Setup migrations as appropriate
    - (optional) Migrate the database
    - (optional) Setup fake data using factory
    - (optional) Create master page (main template)
    - pull in bootstrap via CDN or whatever
    - pull in browserify `<script src="/js/bundle.js">`

    ## Setup vue.js inside Laravel app
    - Define vue.js scope with `<div id="app"></div>`
    - Setup vue.js app entry point by creating `app.js`
    - Install Elixer with `npm install`
    - Install vue.js using `npm install vue --save`
    - Open `app.js` and type the following
    > var Vue = require('vue');
    >
    > new Vue({
    > el: '#app'
    > });