Coder Social home page Coder Social logo

backend's People

Contributors

callmehiphop avatar nathanboktae avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

backend's Issues

New release?

Can you please release a new version to npm? Lots of important changes in since v0.3.1.

npm version 0.2.5 broken

For some reason, the latest version (0.2.5) in npm does not install with the index.js file so it could load the module.

bower.json

I think bower.json needs to be updated to point main to backend.js.

NPM Support?

I use browserify for my client side coding and since then I have moved away from using bower and just sticking with npm for installing all dependencies (having one tool is better than 2 tools for managing dependencies). Now the code here is already written in a CommonJS style so I think making this available on NPM should not be terribly hard, I imagine it is just tweaking the package.json file and just testing.

If this is something you think is a good idea and be willing to accept as a PR, I would probably be able to find some time either this weekend or next to give it a go. What do you think?

Ability to delay response

I know this library is based off of angular's $httpBackend but one thing I hated with that library was it was not easy to delay responses if you wanted to. I have a modified version of this library that I can create a pull request for but before that I want to make sure your good with the functionality and API of doing this. To delay a response in my modified version of the library, the code looks like this:

backend
.when('GET', '/api/users/1')
.options({
    delay: 2000
})
.respond({
    name: 'Jake',
    species: 'Dog',
    magicPowers: true,
    location: 'Ooooo'
}, {
    'content-type': 'application/json'
});

Do you like this functionality and API for enabling it? If so I will create a pull request.

verifyNoOutstandingExpectations and expect API

One of the most powerful features of $httpBackend was the expectGET family of APIs that would assert that a call would happen and only once. Sure there's no $digest cycle (thank god) but we can do the assertions on verifyNoOutstandingExpectations and verifyNoOutstandingRequests during our test cleanup.

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.