From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Achim Gratz Newsgroups: gmane.emacs.devel Subject: Re: Condition to link to javascript code? Date: Sun, 25 Dec 2016 11:04:40 +0100 Message-ID: References: <87eg19uc8y.fsf@gnu.org> <87pokpnn7b.fsf@bzg.fr> <87lgvc8hrp.fsf@bzg.fr> <878trb517w.fsf@bzg.fr> <87oa05h66j.fsf@gmx.us> <87y3z8feig.fsf@gmx.us> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: blaine.gmane.org 1482660349 13844 195.159.176.226 (25 Dec 2016 10:05:49 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 25 Dec 2016 10:05:49 +0000 (UTC) User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Dec 25 11:05:44 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cL5gT-0002ix-GX for ged-emacs-devel@m.gmane.org; Sun, 25 Dec 2016 11:05:41 +0100 Original-Received: from localhost ([::1]:46318 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cL5gY-0007WY-4l for ged-emacs-devel@m.gmane.org; Sun, 25 Dec 2016 05:05:46 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:53634) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cL5ft-0007TT-Bp for emacs-devel@gnu.org; Sun, 25 Dec 2016 05:05:09 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cL5fq-0007bU-8y for emacs-devel@gnu.org; Sun, 25 Dec 2016 05:05:05 -0500 Original-Received: from [195.159.176.226] (port=54783 helo=blaine.gmane.org) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cL5fq-0007a0-3G for emacs-devel@gnu.org; Sun, 25 Dec 2016 05:05:02 -0500 Original-Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1cL5fc-0004dL-2T for emacs-devel@gnu.org; Sun, 25 Dec 2016 11:04:48 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 25 Original-X-Complaints-To: usenet@blaine.gmane.org In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 195.159.176.226 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:210801 Archived-At: Am 24.12.2016 um 19:55 schrieb Richard Stallman: > There is no reason for the initial HTML to refer to klipse.js at all. > Since that is a Javascript program, there is no point fetching it at > all unless Javascript is enabled. The script name and the server address have to be recorded somewhere in the file unless I misunderstood what you are trying to do. > If the URL for loading it is filled in by execution of other previous > JS code, there is no chance of prefetching klipse.js from anywhere. Browsers are quite good at prefetching stuff and some might do it speculatively, so I suspect that the ultimate URL for the script has to be obfuscated a bit so it's only put together when actually used. > So, is there any flaw in this plan? I think it should work if the prefetch can be safely prevented. It's just quite a bit more involved and it would mean distributing multiple files to the user (unless klipse.js can be embedded, optionally of course). -- Achim. (on the road :-)