US9805006B1ActiveUtility

Asynchronous loading of scripts in web pages

82
Assignee: GOOGLE INCPriority: Nov 4, 2009Filed: Mar 28, 2014Granted: Oct 31, 2017
Est. expiryNov 4, 2029(~3.3 yrs left)· nominal 20-yr term from priority
G06F 40/14G06F 16/9574G06F 16/957G06F 17/2247G06F 17/30899
82
PatentIndex Score
5
Cited by
7
References
20
Claims

Abstract

A method of rendering a web page at a client computer identifies a web page selected by a user. The web page references a loadable script that is separate from the web page. The script includes executable code and function definitions. While rendering the web page in a browser or other client resident application, a variable is instantiated to retain information on web page events occurring at the client computer. The script loads asynchronously so that the web page is operable within the client computer system while the script is being loaded. Before the script is fully loaded, one or more command strings representing functions defined in the script are inserted into the variable. After the plurality of function definitions in the script are loaded, one or more functions in the script corresponding to the one or more command strings that were inserted into the variable are executed.

Claims

exact text as granted — not AI-modified
What is claimed is: 
     
       1. A method of loading a web page, comprising:
 providing, via a computer network and to a computing device having one or more processors, a script configured for loading with a web page, the web page configured for display on the computing device, the script having a plurality of function definitions and configured for asynchronous loading such that the web page is operable while the script is loaded; 
 receiving an indication of a user interaction with the web page prior to complete loading of the plurality of function definitions on the web page; 
 determining that the user interaction corresponds to a function definition of the plurality of function definitions that has not been loaded; 
 subsequent to determining that the user interaction corresponds to the function definition that has not been loaded:
 instructing, using a variable, the computing device to queue a command string corresponding to the function definition; 
 determining that the function has been loaded and instructing the computing device to retrieve the command string from the variable; and 
 instructing the computing device to execute the function definition corresponding to the command string. 
 
 
     
     
       2. The method of  claim 1 , further comprising:
 instantiating the variable as a global variable. 
 
     
     
       3. The method of  claim 1 , further comprising:
 instantiating the variable as an array. 
 
     
     
       4. The method of  claim 1 , further comprising:
 identifying an event on the web page. 
 
     
     
       5. The method of  claim 1 , further comprising:
 inserting, via an executable push method of the variable, a new item into the variable. 
 
     
     
       6. The method of  claim 5 , further comprising:
 converting, by the script, the variable to an object type defined in the script. 
 
     
     
       7. The method of  claim 1 , wherein the command string has a corresponding set of one or more parameters. 
     
     
       8. The method of  claim 1 , further comprising:
 determining values of the one or more parameters; and 
 inserting the values and a corresponding command string in the variable. 
 
     
     
       9. The method of  claim 1 , further comprising:
 receiving, by a server having one or more processors, a request for the script; and 
 providing, by the server, the script responsive to the request. 
 
     
     
       10. The method of  claim 1 , further comprising:
 providing, by a server having one or more processors, the script prior to the web page loading. 
 
     
     
       11. A system for loading a web page, comprising:
 one or more processors and memory configured to:
 provide, via a computer network and to a computing device having one or more processors, a script configured for loading with a web page, the web page configured for display on the computing device, the script having a plurality of function definitions and configured for asynchronous loading such that the web page is operable while the script is loaded; 
 receive an indication of a user interaction with the web page prior to complete loading of the plurality of function definitions on the web page; 
 determine that the user interaction corresponds to a function definition of the plurality of function definitions that has not been loaded; 
 subsequent to determining that the user interaction corresponds to the function definition that has not been loaded:
 instruct, using a variable, the computing device to queue a command string corresponding to the function definition; 
 determine that the function has been loaded and instruct the computing device to retrieve the command string from the variable; and 
 instruct the computing device to execute the function definition corresponding to the command string. 
 
 
 
     
     
       12. The system of  claim 11 , wherein the variable is a global variable. 
     
     
       13. The system of  claim 11 , wherein the variable as an array. 
     
     
       14. The system of  claim 11 , wherein the script is an activity tracking script configured to track an event on the web page. 
     
     
       15. The system of  claim 11 , wherein the variable is further configured to:
 insert, via an executable push system of the variable, a new item into the variable. 
 
     
     
       16. The system of  claim 15 , wherein the script is further configured to:
 convert the variable to an object type defined in the script. 
 
     
     
       17. The system of  claim 11 , wherein the command string has a corresponding set of one or more parameters. 
     
     
       18. The system of  claim 11 , wherein the one or more processors are further configured to:
 determine values of the one or more parameters; and 
 insert the values and a corresponding command string in the variable. 
 
     
     
       19. The system of  claim 11 , wherein the one or more processors are further configured to:
 receive a request for the script; and 
 provide the script responsive to the request. 
 
     
     
       20. The system of  claim 11 , wherein the one or more processors are further configured to:
 provide the script prior to the web page loading.

Cited by (0)

No later patents cite this yet.

References (0)

No backward citations on record.