Quantcast
Channel: Help! with 2.0 - Twine Forum
Viewing all articles
Browse latest Browse all 1844

How to add additional JS scripts to Harlowe…

$
0
0
Hi,

I’ve been wondering this for a while… How can we add additional JS scripts (like jQuery plugins) to Harlowe by linking to them?

I have tried the jQuery method:
$(function () {
    $.getScript("http://link.to/js/file.js", function (data, textStatus, jqxhr) {
        console.log(data); // Data returned
        console.log(textStatus); // Success
        console.log(jqxhr.status); // 200
        console.log("Typed was loaded.");
    });
});
…but it doesn’t seem to work.

Is there a "proper" way to do this within Twine? Or do I have to do it after the fact in the published HTML?

Thanks,
Tim

Viewing all articles
Browse latest Browse all 1844

Trending Articles