I am using the Dev branch of the cmv-app and having trouble getting up and running out of the box. It looks like I am unable to start the web server - error says connect.json is not a function.

I installed the node dependencies as described in the 1.3.4 docs. Not sure if anything has changed in 2.0.0 as far as setting up the dev environment. Are there docs specifically for 2.0.0?

  • Which version of the ArcGIS API for JavaScript are you using? – PolyGeo Mar 24 '17 at 0:02
  • same as the dev branch - 3.20 compact – its30 Mar 24 '17 at 0:08
up vote 2 down vote accepted

The problem here is that newer versions of grunt-contrib-connect require the use of an additional nodejs package body-parser to enable the same functionality. I submitted a new Pull Request in the cmv-app repo which addresses this.

This hasn't been tested extensively. I did a basic test the use of grunt connect:dev and the middleware proxy. Most of the current cmv core developers such as myself do not use this approach for a development environment so it doesn't get much attention. Personally, I just use a simple python-based web server. Updates to the CMV docs to describe alternative would be a good idea.

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.