Skip to content

Manage transitions between screens and application state

License

Notifications You must be signed in to change notification settings

jasonford/page-transitions

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

page-transitions

Manage transitions between screens and application state

//  "[* name patterns]" match path segments like:
//  /[element name pattern]+[context name pattern]/...

Structurl.defineElements({
  "[element name pattern]" : function (stringMatchingNamePattern, context) {
    var DOMelement = document.createDocumentFragment();
    //  ...do what you like with the fragment
    //  render a template... throw some div elements together if that's your style...
    //  probably want to render using a template engine... see handlebars example
    return DOMelement;
  }
});

Structurl.defineContexts({
  "[context name pattern]" : function (stringMatchingNamePattern, parentContext, parentELement) {
    var dataForNewContext = {'ooo':'aaaah'};
    return dataForNewContext;
  }
});

add transition="contentName contextName" attribute to any DOM element

About

Manage transitions between screens and application state

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published