Skip to content

Commit

Permalink
Merge branch 'release/6.0.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
Marco Solazzi committed Aug 31, 2017
2 parents be12129 + 10b50dd commit c188717
Show file tree
Hide file tree
Showing 13 changed files with 1,640 additions and 1,504 deletions.
15 changes: 12 additions & 3 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -1,8 +1,17 @@
{
"presets": [
["es2015", {"loose": true, "modules": false}]
["env", {
"modules": false,
"loose": true,
"useBuiltIns": false,
"targets": {
"browsers": ["> 1%", "last 2 versions", "not ie < 11"]
}
}],
"stage-2"
],
"plugins" : [

"plugins": [
["transform-runtime", {"polyfill": false, "regenerator": false }]
]
}
}
3 changes: 3 additions & 0 deletions .stylelintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
],
"rules": {
"indentation": 4,
"at-rule-no-unknown": null,
"max-empty-lines": 3,
"rule-empty-line-before": ["always", {
"ignore": ["after-comment"]
Expand All @@ -24,6 +25,8 @@
"no-missing-end-of-source-newline": null,
"declaration-empty-line-before": "never",

"scss/at-rule-no-unknown": true,

"order/properties-order": [

"position",
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
The MIT License (MIT)

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

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ WOK is a loosely opinionated boilerplate for web development built with flexibil
* [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)
* [BEM](http://blog.kaelig.fr/post/48196348743/fifty-shades-of-bem)-like naming convention
* Em based media-queries via [sass-mq](https://github.com/sass-mq/sass-mq)
* ES2015 support with [Babel](https://babeljs.io/) (polyfill loaded from CDN.js)
* 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)
* [Gulp.js](http://gulpjs.com/) build and deploy workflow
* Development server and asset live-reload with [BrowserSync](http://www.browsersync.io/) and [Weinre](http://people.apache.org/~pmuellr/weinre/) remote debugging
* Incremental deploy with [rsync](https://rsync.samba.org/) or [lftp](http://lftp.yar.ru/)
Expand Down
2 changes: 1 addition & 1 deletion application/views/templates/_default.nunj.html
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ <h1>Hello World!</h1>
{% block main %}
{% endblock %}

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

<!-- build:js /assets/javascripts/application.min.js defer -->
<script defer src="/assets/javascripts/base/plugins.js"></script>
Expand Down
15 changes: 0 additions & 15 deletions build/gulp-config/modernizr.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,6 @@
],
"feature-detects": [
"applicationcache",
"audio",
"audio/loop",
"audio/preload",
"audio/webaudio",
"canvas",
"canvas/blending",
"canvas/todataurl",
Expand Down Expand Up @@ -105,12 +101,6 @@
"custom-protocol-handler",
"customevent",
"dataview-api",
"forms/fileinput",
"forms/fileinputdirectory",
"forms/formattribute",
"forms/inputnumber-l10n",
"forms/placeholder",
"forms/validation",
"fullscreen-api",
"geolocation",
"hashchange",
Expand All @@ -125,7 +115,6 @@
"img/webp-animation",
"img/webp-lossless",
"inputtypes",
"notification",
"pagevisibility-api",
"pointerevents",
"postmessage",
Expand All @@ -141,10 +130,6 @@
"svg/smil",
"touchevents",
"vibration",
"video",
"video/autoplay",
"video/loop",
"video/preload",
"webgl",
"webgl/extensions"
]
Expand Down
3 changes: 1 addition & 2 deletions build/gulp-tasks/deploy.js
Original file line number Diff line number Diff line change
Expand Up @@ -171,5 +171,4 @@ module.exports = (gulp, $, options) => {
});

});
};

};
18 changes: 9 additions & 9 deletions build/gulp-tasks/lib/view-helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ const marked = require('marked');
const Markdown = require('nunjucks-markdown/lib/markdown_tag');
const loremIpsum = require('lorem-ipsum');

module.exports.helpers = function (/*options*/) {
module.exports.helpers = (/*options*/) => {

return {
lorem: function (min, max, config) {
lorem(min, max, config) {
const count = max ? random(min, max) : min;
const loremDefaults = {
units: 'words',
count: count
count
};
const conf = defaults(config || {}, loremDefaults);

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

};

module.exports.nunjucks = function (viewPath) {
module.exports.nunjucks = (viewPath) => {
const env = nunjucks.configure(viewPath, {
noCache: true
});

const markdownTag = new Markdown(env, marked);

markdownTag.fileTag = function (context, file) {
markdownTag.fileTag = (context, file) => {
return new nunjucks.runtime.SafeString(marked(env.render(file, context)));
};

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

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

if (tabStart > 0) { // If the {% markdown %} tag is tabbed in, normalize the content to the same depth.
body = body.split(/\r?\n/); // Split into lines.
// Subtract the column postion from the start of the string.
// Subtract the column options from the start of the string.
body = body.map((line) => line.slice(tabStart));
body = body.join('\n'); // Rejoin into one string.
}
Expand Down
10 changes: 5 additions & 5 deletions build/gulp-tasks/lint.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ module.exports = (gulp, $) => {
gulp.task('lint:styles', () => {

return gulp.src(paths.toPath('src.assets/styles/**/*.{css,sass,scss}'))
.pipe($.stylelint({
reporters: [
{ formatter: 'string', console: true }
]
}));
.pipe($.stylelint({
reporters: [
{ formatter: 'string', console: true }
]
}));
});

gulp.task('lint', ['lint:js', 'lint:styles']);
Expand Down
40 changes: 20 additions & 20 deletions build/gulp-tasks/styles.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ module.exports = (gulp, $, options) => {

function reloadStreamFn() {
if (options.isWatching && options.livereload) {
return reloadStream || (reloadStream = require('browser-sync').get(options.buildHash).stream);
return reloadStream || (reloadStream = require('browser-sync').get(options.buildHash).stream); //eslint-disable-line no-return-assign
}
return $.util.noop;
}
Expand Down Expand Up @@ -49,25 +49,25 @@ module.exports = (gulp, $, options) => {
return gulp.src([
paths.toPath('src.assets/styles/**/*.{sass,scss}')
])
.pipe($.plumber({
errorHandler: $.notify.onError('Error: <%= error.message %>')
}))
.pipe($.sourcemaps.init())
.pipe($.sass({
precision: 10,
includePaths: [paths.toPath('src.assets/vendors'), 'node_modules'],
outputStyle: 'expanded',
functions: sassFunctions
}).on('error', $.sass.logError))
.pipe($.postcss([
autoprefixer({ browsers: ['> 1%', 'last 2 versions', 'ie 9'] })
]))
.pipe($.if(production, productionPipe()))
.pipe($.sourcemaps.write('.'))
.pipe(gulp.dest(paths.toPath('dist.assets/css')))
.pipe(reloadStreamFn()({ match: '**/*.css' }))
.pipe($.if(options.isWatching, $.notify({ message: 'SASS Compiled', onLast: true })))
.pipe($.size({ title: 'styles' }));
.pipe($.plumber({
errorHandler: $.notify.onError('Error: <%= error.message %>')
}))
.pipe($.sourcemaps.init())
.pipe($.sass({
precision: 10,
includePaths: [paths.toPath('src.assets/vendors'), 'node_modules'],
outputStyle: 'expanded',
functions: sassFunctions
}).on('error', $.sass.logError))
.pipe($.postcss([
autoprefixer({ browsers: ['> 1%', 'last 2 versions', 'ie 9'] })
]))
.pipe($.if(production, productionPipe()))
.pipe($.sourcemaps.write('.'))
.pipe(gulp.dest(paths.toPath('dist.assets/css')))
.pipe(reloadStreamFn()({ match: '**/*.css' }))
.pipe($.if(options.isWatching, $.notify({ message: 'SASS Compiled', onLast: true })))
.pipe($.size({ title: 'styles' }));
});

};
2 changes: 1 addition & 1 deletion build/gulp-tasks/views.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ module.exports = (gulp, $, options) => {
.pipe($.rev)
.pipe(() => styleFilter.restore)
.pipe(() => jsFilter)
.pipe($.uglify, { preserveComments: 'license' })
.pipe($.uglify, { output: { comments: 'some' } })
.pipe($.header, options.banners.application, { pkg: options.pkg })
.pipe($.rev)
.pipe(() => jsFilter.restore)
Expand Down
77 changes: 40 additions & 37 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "wok",
"description": "A Static Website Boilerplate",
"version": "5.0.0",
"version": "6.0.0",
"license": "MIT",
"repository": {
"type": "git",
Expand Down Expand Up @@ -30,69 +30,72 @@
},
"dependencies": {
"html5shiv": "3.7.3",
"normalize.css": "6.0.0",
"normalize.css": "7.0.0",
"sass-mq": "3.3.2"
},
"devDependencies": {
"autoprefixer": "6.7.7",
"autoprefixer": "7.1.3",
"babel-core": "6.26.0",
"babel-eslint": "7.2.3",
"babel-plugin-transform-runtime": "6.23.0",
"babel-preset-es2015": "6.24.0",
"babel-runtime": "6.23.0",
"browser-sync": "2.18.8",
"babel-preset-env": "1.6.0",
"babel-preset-stage-2": "6.24.1",
"babel-runtime": "6.26.0",
"browser-sync": "2.18.13",
"customizr": "https://github.com/doctyper/customizr/tarball/develop",
"datauri": "1.0.5",
"del": "2.2.2",
"eslint": "3.18.0",
"eslint-config-airbnb-base": "11.1.2",
"eslint-plugin-import": "2.2.0",
"del": "3.0.0",
"eslint": "4.5.0",
"eslint-config-airbnb-base": "11.3.2",
"eslint-plugin-import": "2.7.0",
"ftps": "1.1.0",
"glob": "7.1.1",
"glob": "7.1.2",
"gulp": "3.9.1",
"gulp-babel": "6.1.2",
"gulp-babel": "7.0.0",
"gulp-bump": "2.7.0",
"gulp-changed": "2.0.0",
"gulp-clean-css": "3.0.4",
"gulp-changed": "3.1.0",
"gulp-clean-css": "3.7.0",
"gulp-concat": "2.6.1",
"gulp-eslint": "3.0.1",
"gulp-filter": "5.0.0",
"gulp-header": "1.8.8",
"gulp-eslint": "4.0.0",
"gulp-filter": "5.0.1",
"gulp-header": "1.8.9",
"gulp-if": "2.0.2",
"gulp-imagemin": "3.2.0",
"gulp-imagemin": "3.3.0",
"gulp-load-plugins": "1.5.0",
"gulp-notify": "3.0.0",
"gulp-plumber": "1.1.0",
"gulp-postcss": "6.4.0",
"gulp-postcss": "7.0.0",
"gulp-rename": "1.2.2",
"gulp-rev": "7.1.2",
"gulp-rev": "8.0.0",
"gulp-rev-replace": "0.4.3",
"gulp-sass": "3.1.0",
"gulp-size": "2.1.0",
"gulp-sourcemaps": "2.4.1",
"gulp-stylelint": "3.9.0",
"gulp-uglify": "2.1.2",
"gulp-sourcemaps": "2.6.1",
"gulp-stylelint": "4.0.0",
"gulp-uglify": "3.0.0",
"gulp-useref": "3.1.2",
"gulp-util": "3.0.8",
"hasbin": "1.2.3",
"image-size": "0.5.1",
"inquirer": "3.0.6",
"image-size": "0.6.1",
"inquirer": "3.2.2",
"lazypipe": "1.0.1",
"lodash": "4.17.4",
"lorem-ipsum": "1.0.3",
"lorem-ipsum": "1.0.4",
"marked": "0.3.6",
"mkdirp": "0.5.1",
"modernizr": "3.4.0",
"node-sass": "4.5.1",
"nunjucks": "3.0.0",
"modernizr": "3.5.0",
"node-sass": "4.5.3",
"nunjucks": "3.0.1",
"nunjucks-markdown": "2.0.1",
"rsyncwrapper": "2.0.1",
"run-sequence": "1.2.2",
"semver": "5.3.0",
"ssh2": "0.5.4",
"stylelint": "7.9.0",
"stylelint-config-standard": "16.0.0",
"stylelint-order": "0.4.1",
"stylelint-scss": "1.4.3",
"run-sequence": "2.1.0",
"semver": "5.4.1",
"ssh2": "0.5.5",
"stylelint": "8.0.0",
"stylelint-config-standard": "17.0.0",
"stylelint-order": "0.6.0",
"stylelint-scss": "2.1.0",
"through2": "2.0.3",
"yargs": "7.0.2"
"yargs": "8.0.2"
}
}
Loading

0 comments on commit c188717

Please sign in to comment.