From c7ef1a10f567cb2f809f481a6633159247030048 Mon Sep 17 00:00:00 2001 From: David Chambers Date: Sun, 29 Apr 2018 17:25:24 +0200 Subject: [PATCH] sanctuary-scripts@1.5.x --- .eslintrc.json | 17 ++++++++++++++++- README.md | 14 +++++++------- package.json | 2 +- 3 files changed, 24 insertions(+), 9 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index d3c776b..27f0e98 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -1,4 +1,19 @@ { "root": true, - "extends": ["./node_modules/sanctuary-style/eslint-es3.json"] + "extends": ["./node_modules/sanctuary-style/eslint-es3.json"], + "overrides": [ + { + "files": ["*.md"], + "plugins": ["markdown"], + "env": {"es6": true, "node": true}, + "globals": {"format": false, "user": false}, + "rules": { + "comma-dangle": ["error", "always-multiline"], + "max-len": ["off"], + "no-unused-vars": ["error", {"varsIgnorePattern": "^format$"}], + "semi": ["error", "never"], + "strict": ["off"] + } + } + ] } diff --git a/README.md b/README.md index b87fd1a..51893fc 100644 --- a/README.md +++ b/README.md @@ -143,11 +143,11 @@ determine the replacement: ```javascript const sheldon = { - firstName: 'Sheldon', - lastName: 'Cooper', - dob: new Date('1970-01-01'), - fullName: function() { return this.firstName + ' ' + this.lastName }, - quip: function() { return 'Bazinga!' }, + firstName: 'Sheldon', + lastName: 'Cooper', + dob: new Date('1970-01-01'), + fullName: function() { return this.firstName + ' ' + this.lastName }, + quip: function() { return 'Bazinga!' }, } '{fullName} was born at precisely {dob.toISOString}'.format(sheldon) @@ -166,7 +166,7 @@ with `!`, after a field name in a template string. ```javascript const fmt = format.create({ escape: s => s.replace(/[&<>"'`]/g, c => '&#' + c.charCodeAt(0) + ';'), - upper: s => s.toUpperCase(), + upper: s => s.toUpperCase(), }) fmt('Hello, {!upper}!', 'Alice') @@ -188,7 +188,7 @@ name in a template string. ```javascript format.extend(String.prototype, { escape: s => s.replace(/[&<>"'`]/g, c => '&#' + c.charCodeAt(0) + ';'), - upper: s => s.toUpperCase(), + upper: s => s.toUpperCase(), }) 'Hello, {!upper}!'.format('Alice') diff --git a/package.json b/package.json index abef881..e561240 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ ], "dependencies": {}, "devDependencies": { - "sanctuary-scripts": "1.4.x" + "sanctuary-scripts": "1.5.x" }, "scripts": { "doctest": "sanctuary-doctest",