How to use Bootsfaces DataTable without loading Sources from CDN

577 views Asked by At

I want to use the Bootsfaces Datatable, but unfortunately it loads two resources from https://cdn.datatables.net, and I am not allowed to include such references in our web application. I did not find a way to load these files from my own webserver yet. The properties that can be set in the web.xml to load your own resources only work for jquery, fontawesome and Bootstrap, if I am not mistaken.

After some research i found that the URL is hardcoded in the constructor of the DataTable class, and calls the AddResourcesListener. Maybe there is some way to tell the Listener to not add the resources for datatable.min.js and datatable.min.css?

1

There are 1 answers

2
andi17 On BEST ANSWER

I found an issue in github regarding this problem:

https://github.com/TheCoder4eu/BootsFaces-OSP/issues/853

As mentioned there, BootsFaces version 1.1.2 does not load the sources from the CDN, which is totally fine for me for now. In future versions there will be an extra jar file to add those sources, but the issue is still open.