-
Notifications
You must be signed in to change notification settings - Fork 120
feat: add lib and es6 bundles, use closure compiler, remove gulp #70
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
Merged
Merged
Changes from 17 commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
ba51883
chore(karma): move karma config to config/karma and update to use web…
frederickfogerty 3f19eba
chore(build): use webpack rather than browserify
frederickfogerty 68cdfb4
chore: use npm scripts rather than gulp
frederickfogerty 69afaf9
fix: update source to work with google closure compiler
frederickfogerty 4c77487
chore: update various things to new build tool
frederickfogerty 7ac5701
Sync with Prettier
prettierci-commits 1a42d60
feat: add browserslist to show what browsers are supported and to hel…
frederickfogerty 168426f
chore(build-js): don't run closure on test files
frederickfogerty 5a58385
Merge branch 'fred/use-webpack' of https://github.com/imgix/drift int…
frederickfogerty 0aa962a
docs(contributing): update build references to npm rather than gulp
frederickfogerty 5f19fa0
chore: remove reference to gulp in bower
frederickfogerty 6a5c4ea
chore(karma): add comments
frederickfogerty a58c622
fix(travis): fix config file (tabs -> spaces)
frederickfogerty 17a3097
chore: remove phantomjs and other deps
frederickfogerty 8bf7357
chore: remove more deps
frederickfogerty 1d1286c
feat(travis): upgrade to node 10
frederickfogerty 340c24c
chore(karma): update ci karma config
frederickfogerty d346485
chore(webpack): remove unused dependencies
frederickfogerty ae352e7
chore(bower): update ignored files
frederickfogerty 846f151
chore(CONTRIBUTING): fix tab alignment
frederickfogerty 3ea92a0
Merge branch 'fred/use-webpack' of https://github.com/imgix/drift int…
frederickfogerty File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,12 @@ | ||
{ | ||
"presets": ["es2015", "stage-0"] | ||
"presets": [["env", { "modules": false }]], | ||
"plugins": [], | ||
"env": { | ||
"commonjs": { | ||
"presets": ["env"] | ||
}, | ||
"test": { | ||
"presets": ["env"] | ||
} | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
### PLACE CUSTOM IGNORES HERE | ||
lib | ||
es | ||
|
||
|
||
|
||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
CHANGELOG.md | ||
package.json | ||
bower.json | ||
es | ||
lib | ||
dist |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ | |
"version": "1.2.2", | ||
"description": "Easily add \"zoom on hover\" functionality to your site's images. Lightweight, no-dependency JavaScript.", | ||
"main": [ | ||
"dist/Drift.js", | ||
"dist/Drift.min.js", | ||
"dist/drift-basic.css" | ||
], | ||
"authors": [ | ||
|
@@ -25,7 +25,6 @@ | |
"src", | ||
"test", | ||
"CONTRIBUTING.md", | ||
"gulpfile.js", | ||
"index.html", | ||
"karmaConfig.js", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Some of the files in this list need updating |
||
"package.json" | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
module.exports = require("./karma.config").ci; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
module.exports = require("./karma.config").local; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,131 @@ | ||
const webpackConfig = require("../../webpack.config"); | ||
|
||
const webpackConfigAugmented = { | ||
...webpackConfig, | ||
module: { | ||
...webpackConfig.module, | ||
rules: [ | ||
// ...webpackConfig.module.rules, | ||
{ | ||
test: /(\.jsx|\.js)$/, | ||
loader: "babel-loader", | ||
exclude: /(node_modules|bower_components)/ | ||
} | ||
] | ||
} | ||
}; | ||
|
||
const baseConfig = { | ||
frameworks: ["jasmine"], | ||
files: [ | ||
{ pattern: "../../src/**/*.js", included: false, served: false, watched: false }, | ||
{ pattern: "../../test/**/test*.js", watched: false } | ||
], | ||
preprocessors: { | ||
"../../src/**/*.js": ["webpack"], | ||
"../../test/**/*.js": ["webpack"] | ||
}, | ||
webpack: webpackConfigAugmented, | ||
webpackMiddleware: { | ||
stats: "errors-only" | ||
}, | ||
concurrency: 5, | ||
captureTimeout: 90000, | ||
browserConnectTimeout: 3000, | ||
browserNoActivityTimeout: 15000 | ||
}; | ||
|
||
const stringConfig = JSON.stringify(baseConfig); | ||
|
||
/** | ||
* Local testing - Chrome and FF, headlessly | ||
*/ | ||
|
||
const localConfig = karmaConfig => { | ||
const config = { | ||
...baseConfig, | ||
browsers: ["ChromeHeadless", "FirefoxHeadless"], | ||
customLaunchers: { | ||
FirefoxHeadless: { | ||
base: "Firefox", | ||
flags: ["-headless"] | ||
} | ||
} | ||
}; | ||
|
||
karmaConfig.set(config); | ||
}; | ||
|
||
/** | ||
* CI testing - Chrome, Firefox | ||
*/ | ||
|
||
const ciConfig = karmaConfig => { | ||
const config = { | ||
...baseConfig, | ||
browsers: ["ChromeTravis", "FirefoxHeadless"], | ||
customLaunchers: { | ||
ChromeTravis: { | ||
base: "ChromeHeadless", | ||
flags: ["--no-sandbox"] | ||
}, | ||
FirefoxHeadless: { | ||
base: "Firefox", | ||
flags: ["-headless"] | ||
} | ||
}, | ||
client: { | ||
mocha: { | ||
timeout: 20000 // 20 seconds | ||
} | ||
} | ||
}; | ||
|
||
karmaConfig.set(config); | ||
}; | ||
|
||
/** | ||
* SauceLabs configuration - not supported | ||
*/ | ||
|
||
var fullConfig = JSON.parse(stringConfig); | ||
fullConfig.reporters = ["progress", "saucelabs"]; | ||
fullConfig.saucelabs = { testName: "Drift Tests" }; | ||
fullConfig.browsers = [ | ||
"sl_chrome", | ||
"sl_safari_9", | ||
"sl_safari_8", | ||
"sl_firefox_42", | ||
"sl_firefox_41", | ||
"sl_ie_11", | ||
"sl_ie_10", | ||
"sl_ios_9", | ||
"sl_ios_8", | ||
"sl_android_5", | ||
"sl_android_4" | ||
]; | ||
fullConfig.customLaunchers = { | ||
sl_chrome: { base: "SauceLabs", browserName: "Chrome" }, | ||
sl_safari_9: { base: "SauceLabs", browserName: "Safari", version: 9 }, | ||
sl_safari_8: { base: "SauceLabs", browserName: "Safari", version: 8 }, | ||
sl_firefox_42: { base: "SauceLabs", browserName: "Firefox", version: 42 }, | ||
sl_firefox_41: { base: "SauceLabs", browserName: "Firefox", version: 41 }, | ||
sl_ie_11: { | ||
base: "SauceLabs", | ||
browserName: "Internet Explorer", | ||
version: "11" | ||
}, | ||
sl_ie_10: { | ||
base: "SauceLabs", | ||
browserName: "Internet Explorer", | ||
version: "10" | ||
}, | ||
sl_ios_9: { base: "SauceLabs", browserName: "iPhone", version: "9.2" }, | ||
sl_ios_8: { base: "SauceLabs", browserName: "iPhone", version: "8.4" }, | ||
sl_android_5: { base: "SauceLabs", browserName: "Android", version: "5.1" }, | ||
sl_android_4: { base: "SauceLabs", browserName: "Android", version: "4.4" } | ||
}; | ||
|
||
exports.local = localConfig; | ||
exports.ci = ciConfig; | ||
exports.full = karmaConfig => karmaConfig.set(fullConfig); |
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nit] Handsome tab spacing is broken here