Wednesday, 26 April 2017

Utilise jQuery plugin with ES6 import

I've installed the jquery plugin summernote using npm and it's within my node_modules directory.

I'm now trying to utilise the summernote function in much the same way as I was before when I was just loading the scripts within the html.

import { summernote } from 'summernote';

export default function () {
    const summernote = $('.editor');
    summernote.summernote();
}

I can't get past the above code throwing summernote.summernote is not a function



via Luke Vincent

No comments:

Post a Comment