Skip to content

Commit

Permalink
added dist
Browse files Browse the repository at this point in the history
  • Loading branch information
disasteroftheuniverse committed Dec 31, 2019
1 parent a8b1c73 commit 940d345
Show file tree
Hide file tree
Showing 7 changed files with 9,842 additions and 1,018 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,6 @@ src/components/old
src/components/old/
ignore
.vscode/*
*.vscode*
*bundle.sh*
*.LICENSE*
2 changes: 2 additions & 0 deletions dist/SuperQuest.full.min.js

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions dist/SuperQuest.slim.min.js

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions dist/SuperQuest.standalone.min.js

Large diffs are not rendered by default.

10,741 changes: 9,726 additions & 1,015 deletions package-lock.json

Large diffs are not rendered by default.

23 changes: 20 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@
"description": "A collection of AFRAME components tailored for use with the Oculus Quest mobile virtual reality headset.",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"push": "push.sh"
"test": "echo \"Error: no test specified\" && exit 1",
"push": "push.sh",
"bundle": "bundle.sh"
},
"keywords": [
"aframe",
Expand Down Expand Up @@ -33,7 +34,23 @@
"oimo": "^1.0.9"
},
"devDependencies": {
"eslint": "^6.8.0"
"eslint": "^6.8.0",
"terser-webpack-plugin": "^2.3.1",
"webpack": "^4.41.5",
"worker-loader": "^2.0.0",
"@babel/core": "^7.7.7",
"@babel/preset-env": "^7.7.7",
"babel-loader": "^8.0.5",
"compression-webpack-plugin": "^3.0.1",
"copy-webpack-plugin": "^5.1.1",
"css-loader": "^2.1.1",
"file-loader": "^3.0.1",
"hard-source-webpack-plugin": "^0.13.1",
"image-webpack-loader": "^6.0.0",
"jshint": "^2.10.3",
"prettier": "^1.19.1",
"style-loader": "^0.23.1",
"webpack-cli": "^3.3.10"
},
"repository": {
"type": "git",
Expand Down
87 changes: 87 additions & 0 deletions webpack.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
/*jshint esversion: 8*/
const path = require('path');
//const HtmlWebpackPlugin = require('html-webpack-plugin');
const webpack = require('webpack');
const TerserPlugin = require('terser-webpack-plugin');
//var AppCachePlugin = require('appcache-webpack-plugin');
//const CompressionPlugin = require('compression-webpack-plugin');
//var HardSourceWebpackPlugin = require('hard-source-webpack-plugin');

module.exports = {
mode: 'production',
entry: {
'SuperQuest.full': path.join(__dirname, 'index'),
'SuperQuest.slim': path.join(__dirname, 'index'),
'SuperQuest.standalone': path.join(__dirname, 'index'),
},
output: {
path: __dirname + '/dist',
filename: '[name].min.js',
//chunkFilename: 'js/vendor/[name].js'
},
module: {
rules: [{
test: /.jsx?$/,
include: [
path.resolve(__dirname, 'src')
],
exclude: [
path.resolve(__dirname, 'node_modules')
],
loader: 'babel-loader',
query: {
presets: [
['@babel/env', {
'targets': {
'browsers': 'last 2 chrome versions'
}
}]
]
}
},
{
test: /\.worker\.js$/,
use: {
loader: 'worker-loader',
options: {
inline: true,
fallback: true,
name: '[name].[hash].js'
}
},
},
]
},
plugins: [

],
resolve: {
extensions: ['.json', '.js', '.jsx']
},
optimization: {
minimizer: [
new TerserPlugin({
extractComments: 'all',
//exclude: /[\\/]angular[\\/]/, adb pull This PC\Quest\Internal shared storage\Oculus\VideoShots\com.oculus.vrshell-20190920-054804.mp4 C:\Users\ppinh\Desktop
// parallel: true,
terserOptions: {
drop_console: false,
ecma: undefined,
warnings: false,
parse: {},
compress: {},
mangle: true, // Note `mangle.properties` is `false` by default.
module: true,
output: null,
toplevel: false,
nameCache: null,
ie8: false,
keep_classnames: undefined,
keep_fnames: false,
safari10: false,
},
test: /\.js(\?.*)?$/i,
}),
],
}
};

0 comments on commit 940d345

Please sign in to comment.