Giter Site home page Giter Site logo

qscompany / q-infinite Goto Github PK

View Code? Open in Web Editor NEW
4.0 2.0 0.0 2.58 MB

MVVM Javascript Framework for mobiles and desktops and whatever !!!!

TypeScript 35.36% CSS 22.59% HTML 0.65% Batchfile 0.01% JavaScript 41.40%
frontend-framework frontend-app framework framework-javascript framework-engine

q-infinite's Introduction

Q-Infinite Framework

اكبر منصة برمجية في العالم العربي و إفريقيا

N|Solid

*** QJs is a Core JavaScipt-Framework, without any dependency & fully costumizable with modern technologies

#Technologies Implimented

  • MVVM (Databinding with a new way)
  • JIT (Just In Time execution)
  • OTE (One Time Execution)
  • Filters
  • Template & Derictives
  • Reflectection
  • module Security
  • Component & Controls
  • Encryption
  • Json (Fully Solution for Recursive Objects -Serialization & Deserialization)
  • Eval Code
  • Api & Commands & Jobs
  • Application Architecture
  • Observable Objects
  • Secure Authentication Over Http
  • Module Loader
  • Plugins
  • Dispatcher (Queued Thread)
  • FormatedString Interpolation (Fast Algo)
  • Query basics (Memery useless)

#Example!

We are Going to Create [2 files][df1]:

  • [Templates.html][df1]
  • [Code.js][df1]

Code.html

    import {bind} from 'js/Corelib';
    export class Person extends bind.DObject{
        static __fields__(){
            this.DPFName=bind.DObject.CreateField("FirstName",String);
            this.DPFName=bind.DObject.CreateField("FirstName",String);
            return [this.DPFName ,this.DPLName];
        }
    }
    
    var myJob = bind.Register({
        Name: "myJob",
        Todo(ji, i) {            
            var value=(ji.Scop.Value||"").trim();
            var d=ji.dom.parent;
            d.style.display= value.length<3 ?'none':  ji.getValue('defaultDisplay');
        },
        OnInitialize(ji, e) {
            ji.addValue('defaultDisplay',ji.dom.parent.style.display);
            this.Todo(ji,e);
        }
    });

Templates.html

    <template name="T1">
        <div class="row">
            <text db-bind="FirstName" db-job="label"></text>
            <span  db-bind="LastName" id='lastNamePanel'>
                <text db-job="label"></text>
                <text style="display:none" db-bind="^.FirstName" db-job="myJob"></text>
            </span>
        </div>
    </template>

How To Execute

in our code we go to impliment this

    var person=new Person();
    var personView=new UI.TControl('templates.T1',person);
    person.FirstName="Achour";
    // look when I change person.FirstName the view doesn't change until 
    //the view impilmented in document
    personView.OnInitialize=view=>{
        //on this point the view has been implimented into document
        // And the #lastNamePanel is hidden because the fisrtName.length<3
        person.FirstName="Achour";
        //On this Point The #lastNamePanel is visble
        person.LastName="Brahim";
    }
    //***********************************************************
    //***** this bloc of code for testing not Standard code ***** 
    //*************don't use it in your project *****************
    personView.Parent=UI.Desktop.Current;
    document.body.appendChid(personView.View);
    //***********************************************************
    // **********  this is how to impliment your code  **********
    //  parentControl.Add(personView);      
    //**********************************************************

Examplae 2 TodoList

Code.html

    import {bind} from 'js/Corelib';
    export class TodoListModel extends bind.DObject{
		constr
        static __fields__(){
            this.DPFName=bind.DObject.CreateField("FirstName",String);
            this.DPFName=bind.DObject.CreateField("FirstName",String);
            return [this.DPFName ,this.DPLName];
        }
    }
    
    var myJob = bind.Register({
        Name: "myJob",
        Todo(ji, i) {            
            var value=(ji.Scop.Value||"").trim();
            var d=ji.dom.parent;
            d.style.display= value.length<3 ?'none':  ji.getValue('defaultDisplay');
        },
        OnInitialize(ji, e) {
            ji.addValue('defaultDisplay',ji.dom.parent.style.display);
            this.Todo(ji,e);
        }
    });

Templates.html

    <template name="T1">
        <div class="row">
            <text db-bind="FirstName" db-job="label"></text>
            <span  db-bind="LastName" id='lastNamePanel'>
                <text db-job="label"></text>
                <text style="display:none" db-bind="^.FirstName" db-job="myJob"></text>
            </span>
        </div>
    </template>
  • this is the basic way how to create simple template but there are many way to do that

q-infinite's People

Contributors

qscompany avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.