Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

resolves #25 - remove deprecated gulp-util #26

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
{
"env": {
"node": true
},
"parserOptions": {
"ecmaVersion": 6
},
"extends": "eslint:recommended",
"rules": {
"semi": [2, "always"],
Expand Down
4 changes: 2 additions & 2 deletions gulpfile.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
/* eslint-disable no-console */

var del = require('del');
var gulp = require('gulp');
var rename = require('gulp-rename');
var jshint = require('gulp-jshint');
var stylish = require('jshint-stylish');
var nodeunit = require('gulp-nodeunit');
var runSequence = require('run-sequence');
var accessSniff = require('access-sniff');
var access = require('./index.js');

gulp.task('clean', function(cb) {
Expand All @@ -14,7 +15,6 @@ gulp.task('clean', function(cb) {
], cb);
});


gulp.task('lint', function() {
return gulp.src(['./libs/*.js', 'gulpfile.js'])
.pipe(jshint())
Expand Down
13 changes: 5 additions & 8 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,10 @@
// ------------------------

// through2 is a thin wrapper around node transform streams
const _ = require('lodash');
const gutil = require('gulp-util');
const through = require('through2');
const accessSniff = require('access-sniff');
const StringDecoder = require('string_decoder').StringDecoder

const PluginError = gutil.PluginError;
const StringDecoder = require('string_decoder').StringDecoder;
const PluginError = require('plugin-error');

// Consts
const PLUGIN_NAME = 'gulp-accessibility';
Expand All @@ -21,7 +18,7 @@ var accessSniffPlugin = function(options) {
return through.obj(function(file, enc, callback) {

if (file.isNull()) {
cb(null, file);
callback(null, file);
}

if (file.isStream()) {
Expand All @@ -47,7 +44,7 @@ var accessSniffPlugin = function(options) {

});

}
};

accessSniffPlugin.report = function(options) {
const gulpOptions = options ? options : {};
Expand All @@ -56,7 +53,7 @@ accessSniffPlugin.report = function(options) {
return through.obj(function(file, enc, callback) {

if (file.isNull()) {
cb(null, file);
callback(null, file);
}

if (file.isStream()) {
Expand Down
Loading