Skip to content

Commit c188717

Browse files
author
Marco Solazzi
committed
Merge branch 'release/6.0.0'
2 parents be12129 + 10b50dd commit c188717

File tree

13 files changed

+1640
-1504
lines changed

13 files changed

+1640
-1504
lines changed

.babelrc

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,17 @@
11
{
22
"presets": [
3-
["es2015", {"loose": true, "modules": false}]
3+
["env", {
4+
"modules": false,
5+
"loose": true,
6+
"useBuiltIns": false,
7+
"targets": {
8+
"browsers": ["> 1%", "last 2 versions", "not ie < 11"]
9+
}
10+
}],
11+
"stage-2"
412
],
5-
"plugins" : [
13+
14+
"plugins": [
615
["transform-runtime", {"polyfill": false, "regenerator": false }]
716
]
8-
}
17+
}

.stylelintrc.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
],
99
"rules": {
1010
"indentation": 4,
11+
"at-rule-no-unknown": null,
1112
"max-empty-lines": 3,
1213
"rule-empty-line-before": ["always", {
1314
"ignore": ["after-comment"]
@@ -24,6 +25,8 @@
2425
"no-missing-end-of-source-newline": null,
2526
"declaration-empty-line-before": "never",
2627

28+
"scss/at-rule-no-unknown": true,
29+
2730
"order/properties-order": [
2831

2932
"position",

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
The MIT License (MIT)
22

33
Original work Copyright (c) 2014 Intesys
4-
Modified work Copyright (c) 2015 - 2016 Marco Solazzi and other contributors
4+
Modified work Copyright (c) 2015 - 2017 Marco Solazzi and other contributors
55

66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ WOK is a loosely opinionated boilerplate for web development built with flexibil
1111
* [Sass](http://sass-lang.com/) 3.4+ with [node-sass](https://github.com/sass/node-sass) and CSS [post-processing](https://github.com/postcss/postcss)
1212
* [BEM](http://blog.kaelig.fr/post/48196348743/fifty-shades-of-bem)-like naming convention
1313
* Em based media-queries via [sass-mq](https://github.com/sass-mq/sass-mq)
14-
* ES2015 support with [Babel](https://babeljs.io/) (polyfill loaded from CDN.js)
14+
* ES support with [Babel](https://babeljs.io/) (supports [babel-env](https://github.com/babel/babel-preset-env) for IE11 and [stage2](https://babeljs.io/docs/plugins/preset-stage-2/). Polyfill loaded from CDN.js)
1515
* [Gulp.js](http://gulpjs.com/) build and deploy workflow
1616
* Development server and asset live-reload with [BrowserSync](http://www.browsersync.io/) and [Weinre](http://people.apache.org/~pmuellr/weinre/) remote debugging
1717
* Incremental deploy with [rsync](https://rsync.samba.org/) or [lftp](http://lftp.yar.ru/)

application/views/templates/_default.nunj.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ <h1>Hello World!</h1>
4141
{% block main %}
4242
{% endblock %}
4343

44-
<script defer src="https://cdnjs.cloudflare.com/ajax/libs/babel-polyfill/6.23.0/polyfill.min.js"></script>
44+
<script defer src="https://cdnjs.cloudflare.com/ajax/libs/babel-polyfill/6.26.0/polyfill.min.js"></script>
4545

4646
<!-- build:js /assets/javascripts/application.min.js defer -->
4747
<script defer src="/assets/javascripts/base/plugins.js"></script>

build/gulp-config/modernizr.conf.json

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,6 @@
1717
],
1818
"feature-detects": [
1919
"applicationcache",
20-
"audio",
21-
"audio/loop",
22-
"audio/preload",
23-
"audio/webaudio",
2420
"canvas",
2521
"canvas/blending",
2622
"canvas/todataurl",
@@ -105,12 +101,6 @@
105101
"custom-protocol-handler",
106102
"customevent",
107103
"dataview-api",
108-
"forms/fileinput",
109-
"forms/fileinputdirectory",
110-
"forms/formattribute",
111-
"forms/inputnumber-l10n",
112-
"forms/placeholder",
113-
"forms/validation",
114104
"fullscreen-api",
115105
"geolocation",
116106
"hashchange",
@@ -125,7 +115,6 @@
125115
"img/webp-animation",
126116
"img/webp-lossless",
127117
"inputtypes",
128-
"notification",
129118
"pagevisibility-api",
130119
"pointerevents",
131120
"postmessage",
@@ -141,10 +130,6 @@
141130
"svg/smil",
142131
"touchevents",
143132
"vibration",
144-
"video",
145-
"video/autoplay",
146-
"video/loop",
147-
"video/preload",
148133
"webgl",
149134
"webgl/extensions"
150135
]

build/gulp-tasks/deploy.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,5 +171,4 @@ module.exports = (gulp, $, options) => {
171171
});
172172

173173
});
174-
};
175-
174+
};

build/gulp-tasks/lib/view-helpers.js

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@ const marked = require('marked');
99
const Markdown = require('nunjucks-markdown/lib/markdown_tag');
1010
const loremIpsum = require('lorem-ipsum');
1111

12-
module.exports.helpers = function (/*options*/) {
12+
module.exports.helpers = (/*options*/) => {
1313

1414
return {
15-
lorem: function (min, max, config) {
15+
lorem(min, max, config) {
1616
const count = max ? random(min, max) : min;
1717
const loremDefaults = {
1818
units: 'words',
19-
count: count
19+
count
2020
};
2121
const conf = defaults(config || {}, loremDefaults);
2222

@@ -26,27 +26,27 @@ module.exports.helpers = function (/*options*/) {
2626

2727
};
2828

29-
module.exports.nunjucks = function (viewPath) {
29+
module.exports.nunjucks = (viewPath) => {
3030
const env = nunjucks.configure(viewPath, {
3131
noCache: true
3232
});
3333

3434
const markdownTag = new Markdown(env, marked);
3535

36-
markdownTag.fileTag = function (context, file) {
36+
markdownTag.fileTag = (context, file) => {
3737
return new nunjucks.runtime.SafeString(marked(env.render(file, context)));
3838
};
3939

4040
// Markdown rendering for the block. Pretty simple, just get the body text and pass
4141
// it through the markdown renderer.
42-
markdownTag.blockTag = function (context, bodFn, tabStartFn) {
42+
markdownTag.blockTag = (context, bodFn, tabStartFn) => {
4343

44-
var body = bodFn(); //eslint-disable-line no-var
45-
const tabStart = tabStartFn(); // The column postion of the {% markdown %} tag.
44+
let body = bodFn(); //eslint-disable-line no-var
45+
const tabStart = tabStartFn(); // The column options of the {% markdown %} tag.
4646

4747
if (tabStart > 0) { // If the {% markdown %} tag is tabbed in, normalize the content to the same depth.
4848
body = body.split(/\r?\n/); // Split into lines.
49-
// Subtract the column postion from the start of the string.
49+
// Subtract the column options from the start of the string.
5050
body = body.map((line) => line.slice(tabStart));
5151
body = body.join('\n'); // Rejoin into one string.
5252
}

build/gulp-tasks/lint.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,11 @@ module.exports = (gulp, $) => {
2020
gulp.task('lint:styles', () => {
2121

2222
return gulp.src(paths.toPath('src.assets/styles/**/*.{css,sass,scss}'))
23-
.pipe($.stylelint({
24-
reporters: [
25-
{ formatter: 'string', console: true }
26-
]
27-
}));
23+
.pipe($.stylelint({
24+
reporters: [
25+
{ formatter: 'string', console: true }
26+
]
27+
}));
2828
});
2929

3030
gulp.task('lint', ['lint:js', 'lint:styles']);

build/gulp-tasks/styles.js

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ module.exports = (gulp, $, options) => {
1717

1818
function reloadStreamFn() {
1919
if (options.isWatching && options.livereload) {
20-
return reloadStream || (reloadStream = require('browser-sync').get(options.buildHash).stream);
20+
return reloadStream || (reloadStream = require('browser-sync').get(options.buildHash).stream); //eslint-disable-line no-return-assign
2121
}
2222
return $.util.noop;
2323
}
@@ -49,25 +49,25 @@ module.exports = (gulp, $, options) => {
4949
return gulp.src([
5050
paths.toPath('src.assets/styles/**/*.{sass,scss}')
5151
])
52-
.pipe($.plumber({
53-
errorHandler: $.notify.onError('Error: <%= error.message %>')
54-
}))
55-
.pipe($.sourcemaps.init())
56-
.pipe($.sass({
57-
precision: 10,
58-
includePaths: [paths.toPath('src.assets/vendors'), 'node_modules'],
59-
outputStyle: 'expanded',
60-
functions: sassFunctions
61-
}).on('error', $.sass.logError))
62-
.pipe($.postcss([
63-
autoprefixer({ browsers: ['> 1%', 'last 2 versions', 'ie 9'] })
64-
]))
65-
.pipe($.if(production, productionPipe()))
66-
.pipe($.sourcemaps.write('.'))
67-
.pipe(gulp.dest(paths.toPath('dist.assets/css')))
68-
.pipe(reloadStreamFn()({ match: '**/*.css' }))
69-
.pipe($.if(options.isWatching, $.notify({ message: 'SASS Compiled', onLast: true })))
70-
.pipe($.size({ title: 'styles' }));
52+
.pipe($.plumber({
53+
errorHandler: $.notify.onError('Error: <%= error.message %>')
54+
}))
55+
.pipe($.sourcemaps.init())
56+
.pipe($.sass({
57+
precision: 10,
58+
includePaths: [paths.toPath('src.assets/vendors'), 'node_modules'],
59+
outputStyle: 'expanded',
60+
functions: sassFunctions
61+
}).on('error', $.sass.logError))
62+
.pipe($.postcss([
63+
autoprefixer({ browsers: ['> 1%', 'last 2 versions', 'ie 9'] })
64+
]))
65+
.pipe($.if(production, productionPipe()))
66+
.pipe($.sourcemaps.write('.'))
67+
.pipe(gulp.dest(paths.toPath('dist.assets/css')))
68+
.pipe(reloadStreamFn()({ match: '**/*.css' }))
69+
.pipe($.if(options.isWatching, $.notify({ message: 'SASS Compiled', onLast: true })))
70+
.pipe($.size({ title: 'styles' }));
7171
});
7272

7373
};

0 commit comments

Comments
 (0)