From fdff2f9e991fd6e8c24feef35d1c660ccd00fc77 Mon Sep 17 00:00:00 2001 From: Luke Childs Date: Wed, 12 Oct 2016 15:34:05 +0100 Subject: [PATCH] Remove babel --- .gitignore | 1 - .npmignore | 1 - package.json | 21 ++----------------- ...be able to be passed in in either order.js | 2 +- ...lsey node globals don't get overwritten.js | 2 +- ... node globals shouldn't get overwritten.js | 2 +- ...ould overwrite DOM globals on each call.js | 2 +- .../Function should return window instance.js | 2 +- ...nction should setup browser environment.js | 2 +- test/Properties arg should set globals.js | 2 +- test/jsdom arg should set jsdom config.js | 2 +- 11 files changed, 10 insertions(+), 29 deletions(-) delete mode 100644 .npmignore diff --git a/.gitignore b/.gitignore index 15318e4..abf97e9 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,3 @@ node_modules .nyc_output -dist npm-debug.log diff --git a/.npmignore b/.npmignore deleted file mode 100644 index 85de9cf..0000000 --- a/.npmignore +++ /dev/null @@ -1 +0,0 @@ -src diff --git a/package.json b/package.json index e94bc81..be55f85 100644 --- a/package.json +++ b/package.json @@ -2,25 +2,11 @@ "name": "browser-env", "version": "2.0.10", "description": "Simulates a global browser environment using jsdom", - "main": "dist/index.js", + "main": "src/index.js", "scripts": { - "prebuild": "rm -rf dist", - "build": "babel -d dist src", - "prebuild:map": "npm run prebuild", - "build:map": "babel --source-maps=true -d dist src", - "pretest": "npm run build:map", "test": "nyc ava test", "lint": "eslint src", - "coverage": "nyc report --reporter=text-lcov | coveralls", - "prepublish": "npm run build" - }, - "babel": { - "presets": [ - "es2015" - ], - "plugins": [ - "add-module-exports" - ] + "coverage": "nyc report --reporter=text-lcov | coveralls" }, "eslintConfig": { "extends": "lukechilds", @@ -52,9 +38,6 @@ }, "devDependencies": { "ava": "^0.15.2", - "babel-cli": "^6.14.0", - "babel-plugin-add-module-exports": "^0.2.1", - "babel-preset-es2015": "^6.9.0", "coveralls": "^2.11.13", "eslint": "^3.5.0", "eslint-config-lukechilds": "^1.9.0", diff --git a/test/Arguments should be able to be passed in in either order.js b/test/Arguments should be able to be passed in in either order.js index 272c891..2d1d833 100644 --- a/test/Arguments should be able to be passed in in either order.js +++ b/test/Arguments should be able to be passed in in either order.js @@ -1,5 +1,5 @@ import test from 'ava'; -import browserEnv from '../dist'; +import browserEnv from '../src'; test(t => { t.is(typeof navigator, 'undefined'); diff --git a/test/Existing falsey node globals don't get overwritten.js b/test/Existing falsey node globals don't get overwritten.js index 54ce93e..42a11a0 100644 --- a/test/Existing falsey node globals don't get overwritten.js +++ b/test/Existing falsey node globals don't get overwritten.js @@ -4,6 +4,6 @@ import test from 'ava'; // globals first test(t => { global.document = false; - require('../dist')(); + require('../src')(); t.is(document, false); }); diff --git a/test/Existing node globals shouldn't get overwritten.js b/test/Existing node globals shouldn't get overwritten.js index 1a01c20..0d928d4 100644 --- a/test/Existing node globals shouldn't get overwritten.js +++ b/test/Existing node globals shouldn't get overwritten.js @@ -1,5 +1,5 @@ import test from 'ava'; -import browserEnv from '../dist'; +import browserEnv from '../src'; test(t => { const origConsole = console; diff --git a/test/Function should overwrite DOM globals on each call.js b/test/Function should overwrite DOM globals on each call.js index d894cac..9c0a4dd 100644 --- a/test/Function should overwrite DOM globals on each call.js +++ b/test/Function should overwrite DOM globals on each call.js @@ -1,5 +1,5 @@ import test from 'ava'; -import browserEnv from '../dist'; +import browserEnv from '../src'; test(t => { t.is(typeof window, 'undefined'); diff --git a/test/Function should return window instance.js b/test/Function should return window instance.js index 21005f3..c385987 100644 --- a/test/Function should return window instance.js +++ b/test/Function should return window instance.js @@ -1,5 +1,5 @@ import test from 'ava'; -import browserEnv from '../dist'; +import browserEnv from '../src'; test(t => { const returnValue = browserEnv(); diff --git a/test/Function should setup browser environment.js b/test/Function should setup browser environment.js index 48da2c7..8222c1e 100644 --- a/test/Function should setup browser environment.js +++ b/test/Function should setup browser environment.js @@ -1,5 +1,5 @@ import test from 'ava'; -import browserEnv from '../dist'; +import browserEnv from '../src'; test(t => { t.is(typeof window, 'undefined'); diff --git a/test/Properties arg should set globals.js b/test/Properties arg should set globals.js index fad411e..d39216f 100644 --- a/test/Properties arg should set globals.js +++ b/test/Properties arg should set globals.js @@ -1,5 +1,5 @@ import test from 'ava'; -import browserEnv from '../dist'; +import browserEnv from '../src'; test(t => { t.is(typeof window, 'undefined'); diff --git a/test/jsdom arg should set jsdom config.js b/test/jsdom arg should set jsdom config.js index 92e28e6..40206c3 100644 --- a/test/jsdom arg should set jsdom config.js +++ b/test/jsdom arg should set jsdom config.js @@ -1,5 +1,5 @@ import test from 'ava'; -import browserEnv from '../dist'; +import browserEnv from '../src'; test(t => { const userAgent = 'Custom user agent';