Coder Social home page Coder Social logo

vivien's Introduction

vivien

vivien is a 0 dependency prototype Node framework that lets you define the flow of your server using JSX.

import { Vivien } from 'vivien-core'
import Middleware from './Middleware'
import Router from './Router'
import Route from './Route'

import { VersionOneRoute, VersionZeroRoute } from './routes'

const App = (props, context, next) => {
  return (
    <Route match="/api">
      <Route path="/v0" component={VersionZeroRoute} />
      <Route path="/v1" component={VersionOneRoute} />
    </Route>
  )
}

Vivien.listen(App, {
  port: 8080
})

And here is an example of what you might find in ./VersionZeroRoute:

export const VerzionZeroRoute = (props, context, next) => {
  return (
    <Send
      statis={200}
      type="json"
      data={{
        foo: true,
        bar: false
      }}
    />
  )
}

Development

In the case that you'd like to see proof that I build such a misfit of a tool and that it works, you'll wanna do something like this:

# clone the project
[email protected]:colshacol/vivien.git && cd vivien

# install devDependencies (no production dependencies!)
yarn

# start that shit up
yarn develop

vivien's People

Stargazers

Hannah Roksanne avatar Kensie Bliss avatar Andrew Idi avatar Jonathan Barthélémy avatar Kay Gosho avatar Juan David Castro avatar Marcelo Dias avatar Ilya Radchenko avatar Colton Colcleasure avatar Dwight Spencer (denzuko@mastodon.social) avatar

Watchers

Dwight Spencer (denzuko@mastodon.social) 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.