The xhtml pages contain
<script src="/javax.faces.resource/jsf.js.jsf?ln=javax.faces&stage=Development" type="text/javascript"></script>
If I remove the scripts the javascript functions do not work as expected. The requirement is to support only .xhtml pages. So, I went ahead and removed servlet-mapping for .jsf in web.xml, which results in javascript functions being executed incorrectly.
So, can we change jsf.js.jsf to jsf.js.xhtml?