-
Notifications
You must be signed in to change notification settings - Fork 2
Home
Moh. Php Master edited this page Jan 10, 2020
·
1 revision
- Easier to use with each call.
- Resources friendly, shouldn't eat all your cake.
- Optimized performance, each call should execute and finish ASAP.
Write and rewrite until it is right. By: hard coder
- Get the library file _z.js and place it in your project folder.
- Include the library in your html file inside
<head>
tag, better if it is The First JavaScript Include:
<head>
<script type="text/javascript" src="_z.js"></script>
</head>
- Done!.
- Edit the
script
tag and addunderZ
attribute to it:
<head>
<script type="text/javascript" src="_z.js" underZ></script>
</head>
- Type your code inside the tag:
<head>
<script type="text/javascript" src="_z.js" underZ>
// add variable to library
_z.var = [ "data", 123 ];
// edit the `var` variable
_z.var["data2"] = { "char": 'c', "num": 9 };
// clone the library to new var
$ = _z;
</script>
</head>
- When the page loads the library, your code will be executed immediately; even if the page is not ready.