beachmachine / ngx-resource-factory Goto Github PK
View Code? Open in Web Editor NEWLicense: Other
License: Other
It is currently not possible to create a ResourceAction/ResourceConfiguration that fetches a list of strings, e.g.:
GET /some/api/
[
"foo",
"bar"
]
Example Code:
@ResourceAction({
method: ResourceActionHttpMethod.GET,
isList: true,
urlSuffix: 'some/api/',
instanceClass: String,
})
getSomeApi: ResourceActionMethod<any, any, string[]>;
It is possible to add multiple params in the URL, but this is currently not documented.
@ResourceAction({
method: ResourceActionHttpMethod.POST,
paramDefaults: [
new ResourceParamDefaultFromPayload('key1', 'key1'),
new ResourceParamDefaultFromPayload('key2', 'key2'),
],
isList: false,
});
The pkAttr is not loading correctly when cases are mixed.
I am using the @ResourceAction
decorator pretty often in my rest resources
but there is some problem with it.
Every new defined Resource subclass got all the resource actions inherited from their "subclass siblings".
I am aware that the TS classes aren't in fact real classes so the way the new props are added to the prototype can lead to the described problem.
The library uses the URL API, which is not compatible with IE11:
https://caniuse.com/#feat=url
This can be solved by using a polyfill:
https://stackoverflow.com/a/49914527/5382179
The library should add the polyfill in the test runner entry point and the documentation for the instalation should have a notice that it is required to add the polyfill when running the app in IE11.
how to add an access_token before sending to server
It prints the following when trying to use with rxjs 6.3:
Error: Can't resolve 'rxjs/Observable'
it is possible to resolve this error by installing rxjs 6.2.2 and rxjs-compat 6.2.2.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.