Framework j.SKY.

In application DEV.SKY. appear javascript Framework j.SKY. All javascript scripts in the application are written in j.SKY. Still much work needs to be done with j.SKY., the code is crude, yet it works perfectly (only in Chrome) in the current DEV.SKY. Therefore, application DEV.SKY. must be run only in Chrome browser. If the code is "crude", you may ask why it is generally presented here... go on reading.


In SKY. the concept of the code crystallization is introduced for the first time. What is crystallization? This is similar to code optimization, but it is perfect. This is taking into consideration all possible criteria for the code assessing as to its quality. Optimization does the same, but optimization finishes when an optimizer takes a strong-willed decision that "the code is optimized." Crystallization is an abstract concept because it does not include a strong-willed decision, that the code is good, it is always considered to be bad and in an ideal way there is always a search for new criteria, which will help assess the code as a bad one, fix its flaws and make it better. What code is it advisable to subject to crystallization? Of course, first and foremost, a reusable code and, above all, the one which is more commonly used.

At the moment in the Internet jQuery. j.SKY. is predominantly used as is a javascript Framework. It is an attempt to make the most crystallized javascript Framework among those existing. At this point in SKY. project it is recommended to use jQuery in all applications except DEV. SKY. and WORK. SKY., where it is advisable to use j.SKY. jQuery is the predecessor of j.SKY. So, what good things we want to take from jQuery and what we do not want to inherit. Bad in jQuery:

What good things we take from jQuery:

The idea of j.SKY: it is clear from the description above, what we want to add and what to delete. j.SKY. starts with two functions $ and $ $. The first function is an add-in over the getElementById, and the second - over getElementsByTagName, but it also has other functionality. Examples:

From the experience of using j.SKY. in application DEV.SKY, you can see that the received code is shorter than in the jQuery, the functionality of j.SKY. is intuitively clear based on typed parameters. j.SKY. is an unfinished, but an interesting experiment aimed at writing a more "crystal" javascript Framework than jQuery. See the example for j.SKY. use in the file _dev/util/v_database.php

Among the most important criteria in addition to minimization and simplification of the code, which are always used with crystallization, is the estimation of frequency of the use of functions, methods, a functional (etc.), in order to give a more simple and shorter form to the most common cases. In j.SKY. it is well implemented, using intuitive judgement, although in the future there will be computer-based retyping of the options for the frequency of use in different aspects of crystallization.