-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #539 from Kitware/fat-bundle
Create a "fat bundle" for use without webpack, etc.
- Loading branch information
Showing
34 changed files
with
212 additions
and
123 deletions.
There are no files selected for viewing
This file contains 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 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 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,4 @@ | ||
# Change Log | ||
|
||
All notable changes to this project will be documented in this file. | ||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. |
This file contains 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,62 @@ | ||
{ | ||
"name": "@candela/all", | ||
"version": "0.20.0", | ||
"description": "Candela all-inclusive library", | ||
"main": "dist/candela-all.js", | ||
"scripts": { | ||
"build": "webpack --mode development", | ||
"clean": "rm -rf dist build", | ||
"lint": "semistandard | snazzy" | ||
}, | ||
"publishConfig": { | ||
"access": "public" | ||
}, | ||
"babel": { | ||
"presets": [ | ||
"@babel/env" | ||
] | ||
}, | ||
"keywords": [], | ||
"author": "Kitware Inc.", | ||
"license": "Apache-2.0", | ||
"semistandard": { | ||
"ignore": [ | ||
"dist", | ||
"build" | ||
] | ||
}, | ||
"dependencies": { | ||
"@candela/core": "^0.20.0", | ||
"@candela/events": "^0.20.0", | ||
"@candela/geojs": "^0.20.0", | ||
"@candela/glo": "^0.20.0", | ||
"@candela/lineup": "^0.20.0", | ||
"@candela/onset": "^0.20.0", | ||
"@candela/sententree": "^0.20.0", | ||
"@candela/similaritygraph": "^0.20.0", | ||
"@candela/size": "^0.20.0", | ||
"@candela/stats": "^0.20.0", | ||
"@candela/treeheatmap": "^0.20.0", | ||
"@candela/upset": "^0.20.0", | ||
"@candela/vega": "^0.20.0" | ||
}, | ||
"devDependencies": { | ||
"@babel/core": "^7.0.0-beta.44", | ||
"@babel/preset-env": "^7.0.0-beta.44", | ||
"@babel/register": "^7.0.0-beta.44", | ||
"babel-loader": "^8.0.0-beta.2", | ||
"istanbul-instrumenter-loader": "^3.0.1", | ||
"karma": "^2.0.2", | ||
"karma-chrome-launcher": "^2.2.0", | ||
"karma-coverage-istanbul-reporter": "^1.4.2", | ||
"karma-tap": "^4.1.3", | ||
"karma-tap-pretty-reporter": "^4.0.0", | ||
"semistandard": "^7.0.5", | ||
"snazzy": "^4.0.0", | ||
"tap-spec": "^4.1.1", | ||
"tape": "^4.9.0", | ||
"tape-catch": "^1.0.6", | ||
"webpack": "^4.6.0", | ||
"webpack-cli": "^2.0.14" | ||
} | ||
} |
This file contains 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,53 @@ | ||
import * as core from '@candela/core'; | ||
import * as events from '@candela/events'; | ||
import * as geojs from '@candela/geojs'; | ||
import * as glo from '@candela/glo'; | ||
import * as lineup from '@candela/lineup'; | ||
import * as onset from '@candela/onset'; | ||
import * as sententree from '@candela/sententree'; | ||
import * as similaritygraph from '@candela/similaritygraph'; | ||
import * as size from '@candela/size'; | ||
import * as stats from '@candela/stats'; | ||
import * as treeheatmap from '@candela/treeheatmap'; | ||
import * as upset from '@candela/upset'; | ||
import * as vega from '@candela/vega'; | ||
|
||
function load (obj, target) { | ||
for (let prop in obj) { | ||
target[prop] = obj[prop]; | ||
} | ||
} | ||
|
||
// Collect all candela components into a single object. | ||
let components = {}; | ||
for (let bundle of [geojs, glo, lineup, onset, sententree, similaritygraph, stats, treeheatmap, upset]) { | ||
load(bundle, components); | ||
} | ||
for (let component in vega) { | ||
if (vega[component] !== vega.VegaView) { | ||
components[component] = vega[component]; | ||
} | ||
} | ||
|
||
// Collect all candela mixings into a single object. | ||
let mixins = {}; | ||
for (let bundle of [events, size]) { | ||
load(bundle, mixins); | ||
} | ||
mixins.VegaView = vega.VegaView; | ||
|
||
let VisComponent = core.VisComponent; | ||
|
||
// Export everything, both as default... | ||
export default { | ||
VisComponent, | ||
components, | ||
mixins | ||
}; | ||
|
||
// ...and non-default. | ||
export { | ||
VisComponent, | ||
components, | ||
mixins | ||
}; |
This file contains 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,26 @@ | ||
import path from 'path'; | ||
|
||
export default { | ||
entry: './src/index.js', | ||
output: { | ||
libraryTarget: 'umd', | ||
path: path.resolve('dist'), | ||
filename: 'candela-all.js' | ||
}, | ||
module: { | ||
rules: [ | ||
{ | ||
test: /\.js$/, | ||
exclude: /node_modules/, | ||
use: { | ||
loader: 'babel-loader', | ||
options: { | ||
presets: [ | ||
'@babel/env' | ||
] | ||
} | ||
} | ||
} | ||
] | ||
} | ||
}; |
This file contains 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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.