jquery - Prevent Unauthorized access to JavaScript files -
is there way prevent unauthorized access javascript files.
<script src="js/myscript.js" type="text/javascript">
users should not able view myscript.js file.
i know ,is possible ? if possible please give me idea. :)
thank you..
it's not possible.
the file must accessible work in pages. server has no way determine if request script
tag, directly typing browser window, etc.
you can minify file make less human-readable. can obfuscate it, although have performance impact on website. these reversible, , wants reverse engineer code still can.
as though, should prepared anyone see anything put online.
Comments
Post a Comment