Merge branch 'master' into 0.10.0

# Conflicts:
#	lib/generate.js
#	lib/utils.js
This commit is contained in:
Sébastien Chopin 2017-03-20 17:53:39 +01:00
commit 1cd5c0d68b
9 changed files with 44 additions and 12 deletions

View File

@ -10,6 +10,7 @@
<a href="https://donorbox.org/nuxt"><img src="https://img.shields.io/badge/Support%20us-donate-41B883.svg" alt="Support us"></a>
</p>
> Nuxt.js is a framework for server-rendered Vue applications (inspired by [Next.js](https://github.com/zeit/next.js))
## 🚧 Under active development, 1.0 will be released soon :fire:

View File

@ -1,4 +1,6 @@
# Using Vuetify.js with Nuxt.js
https://nuxtjs.org/examples/with-vuetify
https://nuxtjs.org/examples/with-vuetify<br>
https://vuetifyjs.com/
*NOTE: Some Vuetify components needs Vue v2.2.x (or later) to work properly (Nuxt currently uses v2.1.x)*

View File

@ -0,0 +1 @@
@require './vendor/vuetify.styl'

View File

@ -0,0 +1,14 @@
// Specify overrides (theme and/or base variables etc.)
// See https://vuetifyjs.com/quick-start
$theme := {
primary: #9c27b0
accent: #ce93d8
secondary: #424242
info: #0D47A1
warning: #ffb300
error: #B71C1C
success: #2E7D32
}
// Import Vuetify styling
@require '~vuetify/src/stylus/main.styl'

View File

@ -1,6 +0,0 @@
<template>
<div>
<nuxt/>
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
</div>
</template>

View File

@ -1,7 +1,18 @@
const { join } = require('path')
module.exports = {
build: {
vendor: ['vuetify']
},
plugins: ['~plugins/vuetify.js'],
css: ['vuetify/dist/vuetify.min.css']
css: [
{ src: join(__dirname, 'css/app.styl'), lang: 'styl' }
],
head: {
link: [
{ rel: 'stylesheet', href: 'https://fonts.googleapis.com/css?family=Roboto' },
{ rel: 'stylesheet', href: 'https://fonts.googleapis.com/icon?family=Material+Icons' }
]
}
}

View File

@ -8,5 +8,9 @@
"dev": "nuxt",
"build": "nuxt build",
"start": "nuxt start"
},
"devDependencies": {
"stylus": "^0.54.5",
"stylus-loader": "^3.0.1"
}
}

View File

@ -16,7 +16,12 @@
</v-sidebar>
<v-content>
<v-container fluid>
<div class="title">Main Content</div>
<div class="title">
<h2>Main content</h2>
<v-btn primary>Primary button</v-btn>
<v-btn secondary>Secondary button</v-btn>
<v-btn success>Success button</v-btn>
</div>
</v-container>
</v-content>
</main>
@ -33,7 +38,7 @@
}
</script>
<style>
<style scoped>
.title {
padding-left: 20px;
}

View File

@ -424,8 +424,8 @@ function webpackWatchAndUpdate () {
function webpackRunClient () {
return new Promise((resolve, reject) => {
const clientConfig = getWebpackClientConfig.call(this)
const serverCompiler = webpack(clientConfig)
serverCompiler.run((err, stats) => {
const clientCompiler = webpack(clientConfig)
clientCompiler.run((err, stats) => {
if (err) return reject(err)
console.log('[nuxt:build:client]\n', stats.toString(webpackStats)) // eslint-disable-line no-console
if (stats.hasErrors()) return reject(new Error('Webpack build exited with errors'))