1

I just added surveyjs to my angular 2 project and am getting a constant error in the console, no matter what I try.

The error I am getting is this.survey.doAfterRenderSurvey is not a function.

I think this is something built into surveyjs. The only code I have for the component is:

Survey.Survey.cssType = "bootstrap";
var survey = new Survey.SurveyModel(this.surveyJSON);
Survey.SurveyNG.render("surveyElement", { model: survey });

Any ideas?

TSV
  • 7,538
  • 1
  • 29
  • 37
  • What's your boilerplate? https://github.com/surveyjs/surveyjs_angular_quickstart repo works ok for me. Probably problem is in dependencies. – TSV Oct 30 '17 at 13:06
  • Can you post a link to your project or [mcve](https://stackoverflow.com/help/mcve)? – TSV Oct 30 '17 at 13:09
  • 2
    I was able to fix it by changing from Survey.SurveyModel to Survey.ReactSurveyModel – Allison Williams Nov 01 '17 at 14:07

0 Answers0