0

How i can Inject any javascript library into component. For instance i want to use Materialize framework in my angular2 app written in typescript.

workaround

This approach throws an error.

not working

1 Answer 1

0

In fact, there are two parts:

  • For compilation. You need to install the corresponding typings or make it available within your dependencies (node_modules). The files with extensions .d.ts

  • For runtime. You need to configure the dependency in the module manager. For example SystemJS.

    See this question for example:


See this question for more details:

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.