Skip to content

Commit

Permalink
Merge branch 'master' into patch-2
Browse files Browse the repository at this point in the history
  • Loading branch information
LinusBorg authored Apr 10, 2017
2 parents fd1ec3c + f7e50be commit 90aad09
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 7 deletions.
1 change: 1 addition & 0 deletions docs/backend.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ If you are building a purely-static app (one that is deployed separately from th
Let's take a look at the default `config/index.js`:

``` js
// config/index.js
var path = require('path')

module.exports = {
Expand Down
1 change: 1 addition & 0 deletions docs/linter.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ If you are not happy with the default linting rules, you have several options:
1. Overwrite individual rules in `.eslintrc.js`. For example, you can add the following rule to enforce semicolons instead of omitting them:

``` js
// .eslintrc.js
"semi": [2, "always"]
```

Expand Down
4 changes: 2 additions & 2 deletions docs/static.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Handing Static Assets
# Handling Static Assets

You will notice in the project structure we have two directories for static assets: `src/assets` and `static/`. What is the difference between them?

Expand Down Expand Up @@ -41,7 +41,7 @@ In comparison, files in `static/` are not processed by Webpack at all: they are
As an example, with the following default values:

``` js
// config.js
// config/index.js
module.exports = {
// ...
build: {
Expand Down
11 changes: 7 additions & 4 deletions template/build/check-versions.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
var chalk = require('chalk')
var semver = require('semver')
var packageConfig = require('../package.json')

var shell = require('shelljs')
function exec (cmd) {
return require('child_process').execSync(cmd).toString().trim()
}
Expand All @@ -12,12 +12,15 @@ var versionRequirements = [
currentVersion: semver.clean(process.version),
versionRequirement: packageConfig.engines.node
},
{
]

if (shell.which('npm')) {
versionRequirements.push({
name: 'npm',
currentVersion: exec('npm --version'),
versionRequirement: packageConfig.engines.npm
}
]
})
}

module.exports = function () {
var warnings = []
Expand Down
4 changes: 3 additions & 1 deletion template/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"private": true,
"scripts": {
"dev": "node build/dev-server.js",
"start": "node build/dev-server.js",
"build": "node build/build.js"{{#unit}},
"unit": "cross-env BABEL_ENV=test karma start test/unit/karma.conf.js --single-run"{{/unit}}{{#e2e}},
"e2e": "node test/e2e/runner.js"{{/e2e}}{{#if_or unit e2e}},
Expand Down Expand Up @@ -82,11 +83,12 @@
"selenium-server": "^3.0.1",
{{/e2e}}
"semver": "^5.3.0",
"shelljs": "^0.7.6",
"opn": "^4.0.2",
"optimize-css-assets-webpack-plugin": "^1.3.0",
"ora": "^1.2.0",
"rimraf": "^2.6.0",
"url-loader": "^0.5.7",
"url-loader": "^0.5.8",
"vue-loader": "^11.3.4",
"vue-style-loader": "^2.0.5",
"vue-template-compiler": "^2.2.6",
Expand Down

0 comments on commit 90aad09

Please sign in to comment.