fix: measurementsAPI issue caused by production build (#842)
* ci: test docs-publish * Specify to use prod * Babel should transpile with env set by webpack * in-progress * in-progress * Polyfill for ie11 and edge features * Ditch polyfills w/ babel - we'll use a service for now * Bump tools version; shift vtk.js up a layer * Specify we shouldn't target older than IE 11 * ditch babel plugins that should be covered by preset-env * Add a top level build demo command * Let our babel config determine settings * Same babel fixes as PWA * Rebuild deps that don't satisfy our target * Mini helper script for excluding all node_modules, except... * Shift vtk.js dep up a layer * Kill core-js * Export in a node happy way * Updated yarn lock * Set NODE_ENV when launching anything w/ WebPack * docs: updated FAQ * docs: on browser support * Add support for redux browser extension * misc. small clean-up * docs: Remove roadmap page; add browser-support to sidebar * Formatting * Remove roadmap links * Formatting * ci: Remove config syntax error * Simplified bug report template * update community request template * Update question's template * simplify build scripts * specify new script names * fix: for measurement api being pruned by minimizer in prod builds * Use named exports * Simplify config * Let's not do so much heavy lifting for a dev-server build * fix dev build * Add hotkeys to demo * fix: jest babel config and env specific configs * Remove call to non-existant command * Shift experimental proposal plugin up a layer * Use `https` * Try with reduced number of package exceptions * Try to resolve cypress issue * Try to fix cypress issue in CI * Skip https
This commit is contained in:
1 parent
25e7232660
commit
49d343941e
63 files changed
+1773
-813
No files matched your search
@@ -0,0 +1,8 @@
|
||||
const path = require('path');
|
||||
const webpackCommon = require('./../../../.webpack/webpack.commonjs.js');
|
||||
const SRC_DIR = path.join(__dirname, '../src');
|
||||
const DIST_DIR = path.join(__dirname, '../dist');
|
||||
|
||||
module.exports = (env, argv) => {
|
||||
return webpackCommon(env, argv, { SRC_DIR, DIST_DIR });
|
||||
};
|
||||
@@ -1,6 +1,6 @@
|
||||
const merge = require('webpack-merge');
|
||||
const path = require('path');
|
||||
const webpackCommon = require('./../../../.webpack/webpack.common.js');
|
||||
const webpackCommon = require('./../../../.webpack/webpack.commonjs.js');
|
||||
const pkg = require('./../package.json');
|
||||
|
||||
const ROOT_DIR = path.join(__dirname, './..');
|
||||
@@ -11,8 +11,6 @@ module.exports = (env, argv) => {
|
||||
const commonConfig = webpackCommon(env, argv, { SRC_DIR, DIST_DIR });
|
||||
|
||||
return merge(commonConfig, {
|
||||
// https://webpack.js.org/configuration/mode/#mode-production
|
||||
mode: 'production',
|
||||
devtool: 'source-map',
|
||||
stats: {
|
||||
colors: true,
|
||||
|
||||
@@ -5,9 +5,10 @@ import getDescription from '../lib/getDescription';
|
||||
import getImageIdForImagePath from '../lib/getImageIdForImagePath';
|
||||
import guid from '../../utils/guid';
|
||||
import studyMetadataManager from '../../utils/studyMetadataManager';
|
||||
import { measurementApiDefaultConfig } from './../configuration.js';
|
||||
|
||||
const configuration = {
|
||||
measurementTools: [],
|
||||
...measurementApiDefaultConfig,
|
||||
};
|
||||
|
||||
export default class MeasurementApi {
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
import log from '../../log';
|
||||
import { timepointApiDefaultConfig } from './../configuration.js';
|
||||
|
||||
const configuration = {};
|
||||
const configuration = {
|
||||
...timepointApiDefaultConfig,
|
||||
};
|
||||
|
||||
const TIMEPOINT_TYPE_NAMES = {
|
||||
prebaseline: 'Pre-Baseline',
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import { TimepointApi, MeasurementApi } from './classes';
|
||||
import { allTools } from './toolGroups/allTools';
|
||||
import {
|
||||
retrieveMeasurements,
|
||||
@@ -10,7 +9,7 @@ import {
|
||||
disassociateStudy,
|
||||
} from './dataExchange';
|
||||
|
||||
MeasurementApi.setConfiguration({
|
||||
const measurementApiDefaultConfig = {
|
||||
measurementTools: [allTools],
|
||||
newLesions: [
|
||||
{
|
||||
@@ -28,9 +27,9 @@ MeasurementApi.setConfiguration({
|
||||
retrieve: retrieveMeasurements,
|
||||
store: storeMeasurements,
|
||||
},
|
||||
});
|
||||
};
|
||||
|
||||
TimepointApi.setConfiguration({
|
||||
const timepointApiDefaultConfig = {
|
||||
dataExchange: {
|
||||
retrieve: retrieveTimepoints,
|
||||
store: storeTimepoints,
|
||||
@@ -38,4 +37,6 @@ TimepointApi.setConfiguration({
|
||||
update: updateTimepoint,
|
||||
disassociate: disassociateStudy,
|
||||
},
|
||||
});
|
||||
};
|
||||
|
||||
export { measurementApiDefaultConfig, timepointApiDefaultConfig };
|
||||
@@ -1,9 +1,6 @@
|
||||
import './configuration';
|
||||
|
||||
import * as tools from './tools';
|
||||
|
||||
import { MeasurementApi, TimepointApi } from './classes';
|
||||
|
||||
import { ConformanceCriteria } from './conformance';
|
||||
import MeasurementHandlers from './measurementHandlers';
|
||||
import getDescription from './lib/getDescription';
|
||||
|
||||
Reference in new issue
Block a user