1

I have an SharePoint hosted app with a list(test). On the Lists/test/AllItems.aspx is there a way to inject JavaScript file with referenc to thirds party Javascript files like datables etc .

Issue with JSLink When i use JSLINK i can format it but i can't

a) Inject a third party javascript file like datables

b) Inject a custom Javascript File to inject Navigation to the page.

2 Answers 2

1

You can assign multiple files to the jslink property of the webpart. It can also be used to load on-crs javascript files like jquery. For example: ~sitecollection/style library/scripts/jQuery.js|~sitecollection/style library/scripts/my-csr-file.js

1

JSLinks on SPOnline can handle any https reference

I pulled this from working code.

    var field = web.get_availableFields().getByTitle( fieldTitle );
    context.load(field);
    context.executeQueryAsync(function () {
        field.set_jsLink(jsLinkUrl);
        field.updateAndPushChanges(true);
        context.executeQueryAsync();
    });

BUT ... I don't do SP Hosted Apps, execute this (as Bookmarklet) with an admin account

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.