Hello all–
We are currently working on building a progressive web app (in React) that we intend to use to collect data POC on tablet devices as part of our PIH EMR distribution.
For data collection, we are going to React components to support collecting and viewing Obs, etc, and I looking around to see what had already been built and @darius pointed me to the bahmni-form-controls repo:
A couple questions:
Are these form controls meant to be used “stand alone” or are they only meant to be used in conjunction within the context of the Form Designer and a form renderer?
Just as I test, I was going to try use the component within our own code, but immediately ran into a error when I attempted to import the component into a file in our project. Specifically, after adding:
import { ObsControl } from “bahmni-form-controls”;
I’m seeing the error below… (I tried adding PropTypes as a dependency, because the underlying error was that PropTypes was not defined, but that didn’t solve the issue).
Any thoughts? Is this a route I should bother exploring at all?
Row.jsx:99 Uncaught TypeError: Cannot read property ‘bool’ of undefined at eval (Row.jsx:99) at Object. (bundle.js:71333) at webpack_require (bundle.js:71276) at eval (controlsParser.js:20) at Object. (bundle.js:71327) at webpack_require (bundle.js:71276) at eval (Container.jsx:16) at Object. (bundle.js:71315) at webpack_require (bundle.js:71276) at eval (index.jsx:8) at Object. (bundle.js:71309) at webpack_require (bundle.js:71276) at eval (multi_bundle:1) at Object. (bundle.js:71303) at webpack_require (bundle.js:71276) at bundle.js:71296 at bundle.js:71299 at webpackUniversalModuleDefinition (bundle.js:71249) at Object…/node_modules/bahmni-form-controls/dist/bundle.js (bundle.js:71256) at webpack_require (bundle.js:679) at fn (bundle.js:89) at Object…/src/components/pages/HomePage.jsx (bundle.js:132089) at webpack_require (bundle.js:679) at fn (bundle.js:89) at Object. (bundle.js:132007) at Object…/src/App.js (bundle.js:132074) at webpack_require (bundle.js:679) at fn (bundle.js:89) at Object…/src/index.js (bundle.js:132183) at webpack_require (bundle.js:679) at fn (bundle.js:89) at Object.0 (bundle.js:132467) at webpack_require (bundle.js:679) at …/…/contrib/reactcomponents/lib/actions/types.js.Object.defineProperty.value (bundle.js:725) at bundle.js:728
Take care, Mark