New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

xander

Package Overview
Dependencies
Maintainers
1
Versions
48
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

xander

Single page app framework

  • 0.14.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
decreased by-66.67%
Maintainers
1
Weekly downloads
 
Created
Source

xander

CircleCI

Overview

Framework for browser apps with uncompromising configuration.

Usage

Installation

npm install --save xander

Examples

Quick start

A minimal app with home and 404 page.

import {boot, Rule, Eval} from 'xander';

// Calling constructor function return React component.
boot({
  debug: false, // optional, enables logging actions to console.
  rootEl: document.body, // optional, determine root node for application.
  routes: [{
    path: '/',
    component: (props) => <div>Hello, World.</div> 
  }, {
    path: '/test_rules',
    component: (props) => (
      <div>
        <Rule exp="SUM(A,B)" values={{ A: 2, B: 4 }} />
        <Eval exp="A + B" values={{ A: 2, B: 4 }} />
        <Rule
          exp={`AND(status = true, country = "Denmark")`}
          values={{ valid: true, country: "Denmark" }}
        />
      </div>
    )
  }, {
    path: '*',
    component: (props) => <div>404</div>
  }])

})

xan server

Do you want a full featured development server with new project setup? Try xan server.

webpack

Do you like to tinker? If so, then Webpack is recommended to bundle your projects. The minimal example provides a simple boilerplate setup. For larger projects, look at the async example which utilizes webpack's code splitting to scale your app.

A link component to hyperlink your app without annoying page refreshes.

import {Link} from 'xander'
<Link to="/buckets" />
<Link type="button" to="/buckets" />
<Link type="button" to="/buckets" type="button" /> // render button tag instead of a

Router

A minimalist routers, supports history API.

import {router} from 'xander'
router.open('/buckets/1')

Use redirect to change the URL without adding an entry to the history state.

router.redirect('/buckets')
Load Routes

Load routes and related configuration.

loadRoutes([{
  path: '/',
  load: loadContent( System.import('./pages/home') )
}])

State management

Use createStore to create immutable stores.

import {createStore} from 'xander'
createStore(name, reducerOrSpec, actionsAndQueries)

For more examples see fluxury.

Keywords

FAQs

Package last updated on 30 Mar 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc