Skip to content
This repository was archived by the owner on Dec 26, 2018. It is now read-only.

Commit d706d82

Browse files
committed
readme
1 parent 192df63 commit d706d82

File tree

1 file changed

+26
-17
lines changed

1 file changed

+26
-17
lines changed

README.md

Lines changed: 26 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,10 @@ module.exports = function (vueify) {
122122
}
123123
```
124124

125+
## Autoprefix by Default
126+
127+
Starting in 5.0.0, all CSS output via vueify will be autoprefixed by default. See [config section](#configuring-options) on customizing the options.
128+
125129
## Enabling Pre-Processors
126130

127131
You need to install the corresponding node modules to enable the compilation. e.g. to get stylus compiled in your Vue components, do `npm install stylus --save-dev`.
@@ -135,28 +139,28 @@ These are the built-in preprocessors:
135139
- coffee-script
136140
- myth
137141

138-
## Pre-Processor Configuration
142+
## Configuring Options
139143

140-
Create a `vue.config.js` file at where your build command is run (usually y the root level of your project):
144+
Create a `vue.config.js` file at where your build command is run (usually the root level of your project):
141145

142146
``` js
143-
module.exports = function (vueify) {
144-
145-
// configure the options for a built-in language
146-
vueify.option('sass', {
147+
module.exports = {
148+
// configure a built-in compiler
149+
sass: {
147150
includePaths: [...]
148-
})
149-
150-
// register a custom compile function for <script lang="es">
151-
vueify.register({
152-
lang: 'es',
153-
type: 'script',
154-
compile: function (content, cb) {
155-
// transform the content...
156-
cb(null, content)
151+
},
152+
// configure autoprefixer
153+
autoprefixer: {
154+
browsers: ['last 2 versions']
155+
},
156+
// register custom compilers
157+
customCompilers: {
158+
// for tags with lang="ts"
159+
ts: function (content, cb) {
160+
// compile some TypeScript...
161+
cb(null, result)
157162
}
158-
})
159-
163+
}
160164
}
161165
```
162166

@@ -236,6 +240,11 @@ If you use Webpack, there's also [vue-loader](https://github.com/vuejs/vue-loade
236240

237241
## Changelog
238242

243+
### 5.0.0
244+
245+
- New: CSS output is now autoprefixed by default.
246+
- Changed: [New config file format](#configuring-options)
247+
239248
### 4.0.0
240249

241250
- Support ES2015 by default.

0 commit comments

Comments
 (0)