Hello I have an angular 2 project which works fine. Now i want to include an external directive from a js i am loading via a script tag i.e. https://test.com/testDirectiveLoad.js this js contains a directive . When i put the script and the directive in the index.html file the directive works. But i want to include the directive in one of my Components for example headerComponent.ts. If i put the directive in that component the browser displays an error:
Template parse errors:
'test' is not a known element:
1. If 'test' is an Angular component, then verify that it is part of this module.
2. If 'test' is a Web Component then add "CUSTOM_ELEMENTS_SCHEMA" to the '@NgModule.schema' of this component to suppress this message.
Can somebody please help me