New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@blackbox-vision/ra-data-jsonapi-microservices

Package Overview
Dependencies
Maintainers
2
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@blackbox-vision/ra-data-jsonapi-microservices

React Admin data provider with support for microservices using JSON API

  • 1.0.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
2
Weekly downloads
 
Created
Source

Micro Services JSON API DataProvider

React Admin DataProvider with support for micro-services architecture with JSON API Spec.

Install

You can install this library via NPM or YARN.

NPM

npm i @blackbox-vision/ra-data-jsonapi-microservices

YARN

yarn add @blackbox-vision/ra-data-jsonapi-microservices

Use case

You use react-admin for building a frontend to manage CRUD resources, and you have a micro-service architecture for your services.

Example Usage

Normal usage

import React from 'react';
import { Admin, Resource } from 'react-admin';
import { microServicesJsonApiProvider } from '@blackbox-vision/ra-data-jsonapi-microservices';

import { PostList } from './posts';

const dataProvider = microServicesJsonApiProvider({
  posts: 'http://posts.api.url',
});

const App = () => (
  <Admin dataProvider={dataProvider}>
    <Resource name="posts" list={PostList} />
  </Admin>
);

export default App;

Passing a custom HTTP Client

import React from 'react';
import { Admin, Resource } from 'react-admin';
import { microServicesJsonApiProvider } from '@blackbox-vision/ra-data-jsonapi-microservices';

import { PostList } from './posts';

const customHttpClient = (url, options = {}) => {};
const dataProvider = microServicesJsonApiProvider(
  { posts: 'http://posts.api.url' },
  customHttpClient,
);

const App = () => (
  <Admin dataProvider={dataProvider}>
    <Resource name="posts" list={PostList} />
  </Admin>
);

export default App;

Issues

Please, open an issue following one of the issues templates. We will do our best to fix them.

Contributing

If you want to contribute to this project see contributing for more information.

License

Distributed under the MIT license. See LICENSE for more information.

Keywords

FAQs

Package last updated on 27 May 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc