aor-firebase-client icon indicating copy to clipboard operation
aor-firebase-client copied to clipboard

Problem Code

Open erickvictor opened this issue 6 years ago • 10 comments

'./reference' does not contain an export named 'AUTH_CHECK'.

import React from 'react'; import { Admin, Resource } from 'admin-on-rest'; import { RestClient } from 'aor-firebase-client'; import { PostList } from './posts';

const firebaseConfig = { apiKey: "", authDomain: "", databaseURL: "", storageBucket: "", messagingSenderId: "" };

const clientOptions = { timestampFieldNames: { createdAt: 'createdAt', updatedAt: 'updatedAt' }, trackedResources: { name: 'posts', // The name reference to be used in all other places in AOR path: 'blog', // The path in the database. If missing will use the name public: true, uploadFields: [] // The string name of the field } // A single string assumes path and name as equal, non private and without upload fields }

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

export default App;

erickvictor avatar May 04 '18 13:05 erickvictor

Are you using the new react-admin? I know this issue happens on the new react-admin, to use this plugin you must use admin-on-rest.

almahdi avatar Jun 08 '18 20:06 almahdi

@almahdi I'm with less time than should, but I want to take some time to update it to the new admin...

sidferreira avatar Jun 10 '18 15:06 sidferreira

@sidferreira I'm working on it since I need it for a project. Once I'm done I shall submit a PR.

almahdi avatar Jun 10 '18 15:06 almahdi

@almahdi Did you manage to complete this? We are also using the latest react-admin. Thanks!

afilp avatar Jul 19 '18 12:07 afilp

@afilp @almahdi Hey guys, deeply sorry for not replying. I'm very limited in my free time ATM, also I'm not using in my company anymore. I do need to take a time and kinda fully update it to react-admin.

If someone wants to take over it, I have no problems on that.

sidferreira avatar Jul 20 '18 12:07 sidferreira

@afilp @sidferreira I have copied over the sources and modified them to work with my project. So yeah I got it working and its working perfectly. However, I got busy with the project.

I will try to make some time this week to send a pull request.

almahdi avatar Jul 20 '18 18:07 almahdi

@almahdi feel free to email me too, I'll try to get some time to work on it

sidferreira avatar Jul 20 '18 18:07 sidferreira

@sidferreira Thanks a lot for trying to find some time to work on this package! Is it possible that you also update it to support react-admin instead of admin-on-rest? (i.e. support the latest react-admin package) Thanks again!

afilp avatar Jul 21 '18 07:07 afilp

Hi @almahdi , I'm glad to read that you go it working, do you have your changes uploaded to your fork ? it would be nice to share them so we don't duplicate efforts. thank you !

alfonsodev avatar Sep 03 '18 15:09 alfonsodev

Hi @almahdi , I have the same problem and i can´t solve it. How did you resolve it?

Regards,

javim89 avatar Sep 06 '18 21:09 javim89