Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/Model.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ export default class Model {
*/
constructor(config = {}) {
const {
adjustment = null,
filepath = null,
headers = {},
filesystem = false,
Expand All @@ -40,6 +41,9 @@ export default class Model {
if (!filepath) {
throw new Error('[Model] path to protobuf-serialized model definition file is missing.')
}

this.adjustment = adjustment;

this.filepath = filepath

// HTTP(S) headers used during data fetching
Expand Down Expand Up @@ -143,6 +147,9 @@ export default class Model {
console.log(err)
this._interrupt()
}

this.modelConfig = this.adjustment(this.modelConfig);

this.events.emit('loadingProgress', 100)

// build directed acyclic graph
Expand Down