angularjs: Support HttpParamSerializer interface

This commit is contained in:
Thanabodee Charoenpiriyakij
2016-03-19 20:30:10 +07:00
parent c4309e0e64
commit 5256422ee7
2 changed files with 15 additions and 0 deletions

View File

@@ -1110,3 +1110,10 @@ function doBootstrap(element: Element | JQuery, mode: string): ng.auto.IInjector
debugInfoEnabled: false
});
}
function testIHttpParamSerializerJQLikeProvider() {
let serializer: angular.IHttpParamSerializer;
serializer({
a: "b"
});
}

View File

@@ -1916,4 +1916,12 @@ declare namespace angular {
}
}
/**
* $http params serializer that converts objects to strings
* see https://docs.angularjs.org/api/ng/service/$httpParamSerializer
*/
interface IHttpParamSerializer {
(obj: Object): string;
}
}