I have encountered an issue while trying to render an external input template in my Angular Component. The 'http' module is not being found, even though I have installed @types/node in the project. This has failed to resolve the dependency.
Here is the code snippet I am using:
<div style="height: 300px;">
<div [innerHTML]="stepTemplate"></div>
</div>
setView() {
const temp = this.inputModel.templateUrl;
this.stepTemplate = this.http.get(temp).map((html: any) => this.stepTemplate = html);
}
import * as Http from 'http';
export class JourneyLineComponent implements OnInit, AfterViewInit {
.....
http: Http;
}