How to add any external JavaScript file in my Ember CLI component?

209 views Asked by At

enter image description here

I am new to Ember CLI and I don't know how to add my own util file in my app.

I want to add this summernote.js file to my project.

How do I add this file to the components using Ember CLI?

1

There are 1 answers

6
Daniel On

You need to use import keyword in your component file. Example app/components/my-component:

import Ember from 'ember';
import MyUtil from '../utils/my-util';

// ... you can use MyUtil here
// ... rest of file