Narwhal Parade Maestro

    n-rules

    0.0.2 • Public • Published

    Node-Rules

    Beginnings of a rule engine for NodeJS

    - Your rules should be a first class citizen of your API
    - This is being built with some ideas taken from GraphQL
    

    Examples

    import nRules from 'n-rules';
     
    const types = `
      @Secure(LoggedIn)
      userTask checkItOut(create: Chicken) {
     
      }
     
      serverTask updateSomeStuff: Banana {
     
      }
    `;
     
    const resolvers = {
      checkItOut: () => "winning"
    }
     
    /*
      Just declare your task and resolvers.
      userTasks will be turned into RESTful endpoints
    */
    nRules(types, resolvers);

    Install

    npm i n-rules

    DownloadsWeekly Downloads

    1

    Version

    0.0.2

    License

    MIT

    Last publish

    Collaborators

    • logixbomb