Skip to content

Commit

Permalink
Convert node exports to harmony
Browse files Browse the repository at this point in the history
  • Loading branch information
John Bartos authored and mangui committed Jul 18, 2017
1 parent f753155 commit 41ad20c
Show file tree
Hide file tree
Showing 7 changed files with 24 additions and 11 deletions.
2 changes: 1 addition & 1 deletion src/events.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module.exports = {
export default {
// fired before MediaSource is attaching to media element - data: { media }
MEDIA_ATTACHING: 'hlsMediaAttaching',
// fired when MediaSource has been succesfully attached to media element - data: { }
Expand Down
2 changes: 1 addition & 1 deletion src/helper/buffer-helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,4 +83,4 @@ const BufferHelper = {
}
};

module.exports = BufferHelper;
export default BufferHelper;
4 changes: 0 additions & 4 deletions src/index.js

This file was deleted.

2 changes: 1 addition & 1 deletion src/utils/binary-search.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,4 @@ var BinarySearch = {
}
};

module.exports = BinarySearch;
export default BinarySearch;
2 changes: 1 addition & 1 deletion src/utils/hex.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ const Hex = {
}
};

module.exports = Hex;
export default Hex;
2 changes: 1 addition & 1 deletion src/utils/timeRanges.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ const TimeRanges = {
}
};

module.exports = TimeRanges;
export default TimeRanges;
21 changes: 19 additions & 2 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,25 @@ var webpack = require('webpack')

var buildVersion = process.env.BUILD_VERSION || 'full'

var config = {
entry: './src/index.js',
const buildConstants = {
__VERSION__: JSON.stringify(pkgJson.version),
__BUILD_VERSION__: process.env.BUILD_VERSION || 'full'
};

const uglifyJsOptions = {
screwIE8: true,
stats: true,
compress: {
warnings: false
},
mangle: {
toplevel: true,
eval: true
}
};

const commonConfig = {
entry: './src/hls.js',
module: {
rules: [
{
Expand Down

0 comments on commit 41ad20c

Please sign in to comment.