GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — asta4js/README.md at master · astamuse/asta4js

Expand file tree

/

README.md

Copy path
More file actions
More file actions

Latest commit

 

History

History
History
97 lines (64 loc) · 3.59 KB
/

README.md

Copy path

File metadata and controls

97 lines (64 loc) · 3.59 KB
Raw
Copy raw file
Download raw file
Outline
Edit and raw actions

Asta4js is a MVVM framework which allows independent html template and separate rendering/binding logic to independent js file from html template.

Overview

  • pure html template and separated binding

    There is a simple html template which contains a text input and a preview text label.

    <div>2w bingind<input name="name"></div>
    <div>1w binging:<span id="name-preview"></span></div>

    Then we can bind the two DOM elements with the javascript model as following:

      Aj.init(function($scope){
        $scope.data = {};
        $scope.snippet("body").bind($scope.data, {
            name:[
               Aj.form(), //bind the $scope.data.name to input[name=name] in 2-way
               "#name-preview" //bind the $scope.data.name to #name-preview in 1-way
            ]
        });
      });

    A complete sample of todoApp shows how we can make things amazing.

  • web component support

    Asta4js supports web component as well, thus we can develope our application on component base as the same as what react or polymer does.

    Even that Asta4js can make use of polymer's components by treating them as standard web component. The mozilla brick can be integrated as well. The details can be found at our wiki page Web Component Developing

Plenty examples can be found at http://astamuse.github.io/asta4js

User guide is at Asta4js wiki

Why Asta4js

We have been practicing separating rendering/binding logic from the front-end template files for years, and we believe that separated rendering/binding is the best way to release the productivity of developers and designers both since they can completely work independently.

We had created a server side framework Asta4D to achieve our goal years ago,nowadays we believe it is the time to create one for client side programming, thus we created Asta4js.

development

run all test

grunt test

run certain test on chrome

grunt wtestc -file test/e2e/virtual_path_in_array_test.js

dev build

grunt dev

dev watch

grunt watch

status and road map

Currently, Asta4js is still in alpha developing, which means it still lacks of some important functionalities, but it can be considered as stable for existing functions because we are using it in our service developing.

Todo things:

  • build
    • it seems that karma is not a good option for common unit test purpose.(waiting)
    • CI support(better with sauce)(waiting)
    • source format and jshint(waiting)
  • core
    • remove dependency of JQuery, use document.querySelector instead(waiting)
    • add test for multiple select(waiting)
    • add support for option group of select(waiting)
    • performance enhancement, especially for array binding which current implementation is inefficient(waiting)
    • api enhancement for better development friendliness.(in progress)
  • example
    • reimplement the todoApp example to follow the todoMVC's guide line and submit it to todoMVC.(waiting)
  • spa
    • to confirm what else we need for a single page application?(being considered)

Any issue report or contribution/PR is appreciated, especially for the waiting items in above todo things. You can also open issues for discussion.

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.