Releases: ressurectit/ng-rest
Releases · ressurectit/ng-rest
v13.0.1
v13.0.0
Features
- updated
ParameterTransformFunc
interface- added new parameter
args
, used for passing all arguments from method
- added new parameter
- updated
HeaderParameterMiddleware
middleware- updated to use new
handleHeaderParam
function and to pass parameters args to transform function
- updated to use new
- updated
PathParameterMiddleware
middleware- updated to use new
handlePathParam
function and to pass parameters args to transform function
- updated to use new
- updated
QueryObjectParameterMiddleware
middleware- updated to use new
handleQueryObjectParam
function and to pass parameters args to transform function
- updated to use new
- updated
QueryParameterMiddleware
middleware- updated to use new
handleQueryParam
function and to pass parameters args to transform function
- updated to use new
- updated
BodyParameterMiddleware
middleware- updated to pass parameters args to transform function
- updated
ParameterTransform
decorator- now passes args to transform functions
BREAKING CHANGES
- updated
handleQueryParam
function- now requires 3rd parameter
args
, which contains all arguments passed to method
- now requires 3rd parameter
- updated
handleHeaderParam
function- now requires 3rd parameter
args
, which contains all arguments passed to method
- now requires 3rd parameter
- updated
handlePathParam
function- now requires 3rd parameter
args
, which contains all arguments passed to method
- now requires 3rd parameter
- updated
handleQueryObjectParam
function- now requires 4th parameter
args
, which contains all arguments passed to method
- now requires 4th parameter
v12.1.4
Bug Fixes
- fixed
ParamsDataIterator
optional parameters are only withundefined
value,null
value is not considered optional - fixed
handleQueryParam
, now skips optional parameters (undefined
andnull
) - fixed
handleHeaderParam
, now skips optional parameters (undefined
andnull
) - fixed
handlePathParam
, optional parameters (undefined
andnull
) are replaced by empty string
v12.1.3
v12.1.2
v12.1.1
v12.1.0
Features
- new
ParamsDataIterator
class, that is iterator for params data - new
ParamsDataIteratorItem
interface, that represents item during iteration of params data - new
handleQueryParam
function, that handles query param and fills params dictionary - new
handleHeaderParam
function, that handles header param and fills headers dictionary - new
handlePathParam
function, that handles path param and return updated url - new
handleQueryObjectParam
function, that handles query object param and fills serialized query string array - new
mergeQueryObjectParamsWithHttpParams
function, that merges serialized query objects data with existing http params
v12.0.0
Features
- all middlewares are now treeshakeable if not used
- new
middlewareTypes
type, that contains array of middleware names that are built-in - new
RestMiddlewareType
type, that represents definition of type that implementsRestMiddleware
- new
RestMiddlewareOrderType
type, that represents definition of type that is used for definition of order of middlewares - updated
BASIC_DEFAULT_REST_MIDDLEWARES_ORDER
constant- now is treeshakable
- contains all built-in middlewares
- now is of type
RestMiddlewareOrderType[]
- updated
REST_MIDDLEWARES_ORDER
injection token- now injects type
RestMiddlewareOrderType[]
- now injects type
- updated
AdvancedCacheMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
BodyParameterMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
CacheMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
ClearAdvancedCacheMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
HeaderParameterMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
HeadersMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
IgnoredInterceptorsMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
LoggerMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
MockLoggerMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
PathParameterMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
ProducesMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
ProgressIndicatorGroupMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
QueryObjectParameterMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
QueryParameterMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
ReportProgressMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
ResponseTransformMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- updated
ResponseTypeMiddleware
middleware, now middleware type has staticid
to correspond withRestMiddlewareType<RestMiddleware>
- new
@anglr/datetime
dependency version3.0.0
- new
@anglr/rest/datetime
subpackage - subpackage
@anglr/rest/datetime
- new
DatetimeRestDateApi
service, that isRestDateApi
implementation using@anglr/datetime
- new
DATETIME_REST_DATE_API
injection token used as provider for RestDateApi using datetime
- new
BREAKING CHANGES
- minimal supported version of
@angular
is14.0.0
- minimal supported version of
@anglr/common
is11.2.0
- dropped support of
NodeJs
version12
- removed subpackage
@anglr/rest/date-fns
in favor of@anglr/datetime
- removed subpackage
@anglr/rest/moment
in favor of@anglr/datetime
- removed
date-fns
dependency - removed
moment
dependency - updated
REST_METHOD_MIDDLEWARES
injection token- now injects type
RestMiddlewareType<RestMiddleware>[]
- now injects type
- updated
BASIC_DEFAULT_REST_METHOD_MIDDLEWARES
constant- now is of type
RestMiddlewareType<RestMiddleware>[]
- now is of type
- updated
buildMiddlewares
function, now using new middlewares and middlewareOrder types - updated
not
function, now using middleware typeRestMiddlewareType<RestMiddleware>
- updated
getType
function, now using middleware typeRestMiddlewareType<RestMiddleware>
- updated
isNotType
function, now using middleware typeRestMiddlewareType<RestMiddleware>
- updated
DisableMiddleware
decorator, now using middleware typeRestMiddlewareType<RestMiddleware>
- updated
NotType
class- new constructor type
RestMiddlewareType
- new generic constraint
TType extends RestMiddleware
- new constructor type
- updated
RestMethodMiddlewares
interfacemiddlewareTypes
is now of typeRestMiddlewareType<RestMiddleware>[]
- updated
ParametersMiddlewaresMetadata
interfacemiddlewareTypes
is now of typeRestMiddlewareType<RestMiddleware>[]
- updated
BuildMiddlewaresFn
interface- parameter
middlewares
is now of typeRestMiddlewareType<RestMiddleware>[]
- parameter
middlewaresOrder
is now of typeRestMiddlewareOrderType[]
- parameter
- updated
RESTClient
class- parameter
methodMiddlewares
is now of typeRestMiddlewareType<RestMiddleware>[]
- parameter
middlewaresOrder
is now of typeRestMiddlewareOrderType[]
- parameter
v11.2.0
Features
- new
REST_MOCK_LOGGER
injection token used for injecting MockLogger used for logging responses for mocks - new
MockLogger
interface, that is service for logging mock responses- method
logResponse
logs mock response
- method
- new
MockLoggerMiddleware
middleware, that is used for logging responses for mock usages - new
AdvancedCacheItem
interface, that is advanced cache item- property
response
cached http response - property
validUntil
validity date for cache
- property
- new
AdvancedCacheItemOptions
type, that are options for advanced cache item - new
AdvancedCacheService
service, that allows advanced caching of http responses- method
clearCache
clears cache either for specified key, or whole cache - method
add
adds response to advanced cache - method
get
gets http response from cache, or null if it does not exists - method
updateCache
updates existing cache items, if not exists it does nothing
- method
- new
RestAdvancedCaching
interface, contains data that are used for advanced cache service- extends
RestClearAdvancedCaching
- property
validUntil
relative definition of 'date' for setting validity of cache, example +2d, +12h
- extends
- new
RestClearAdvancedCaching
interface, contains data that are used for clearing advanced cache service- property
key
key to stored cache item
- property
- new
AdvancedCache
decorator, results of requests are cached in advanced cachce service - new
AdvancedCacheMiddleware
middleware, that is used for storing and restoring response from advanced cache service - new
ClearAdvancedCacheMiddleware
middleware, that is used for clearing advanced cache for specific key - new
ClearAdvancedCache
decorator, that clears advanced cache for key when call is successful - updated
RestDateApi
interface- method
isBeforeNow
tests whether tested date is before now
- method
- subpackage @anglr/rest/date-fns
- updated
DateFnsRestDateApi
to correspond with newRestDateApi
interface
- updated
- subpackage @anglr/rest/moment
- updated
MomentRestDateApi
to correspond with newRestDateApi
interface
- updated