Skip to content

Commit

Permalink
Delete pubspec.lock to fix merge conflict error
Browse files Browse the repository at this point in the history
  • Loading branch information
Dahkenangnon committed Nov 25, 2020
2 parents 9d6ccd3 + 5ffb3cd commit 54e3259
Show file tree
Hide file tree
Showing 13 changed files with 631 additions and 582 deletions.
13 changes: 9 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,18 @@
## 0.0.7

## 0.1.0

## 0.0.1+1
- Improvment: Documentation of the code
- Breaking: on both rest and socketio, you get exactly what feathers js send, we don't support any serializer or deserializer. So how previous version handle data is breaken
- Feature: Add event listen but not fully tested
- Authentication don't matter if you auth user with email/password. You can use email/password, phone/password, userName/password
- Feature: support now phone, email, etc, with password authentication

- remove unsed comment
## 0.0.1
## 0.0.7

- remove unused comment
- Add formData handling
- Update readme

## 0.0.6-dev

- Fix
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# The MIT License (MIT)

Copyright (c) 2019 Justin Dah-kenangnon <dah.kenangnon@gmail.com>
Copyright (c) 2020-present Justin Dah-kenangnon <dah.kenangnon@gmail.com>

> Permission is hereby granted, free of charge, to any person obtaining a copy
> of this software and associated documentation files (the "Software"), to deal
Expand Down
33 changes: 23 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
# flutter_feathersjs :bird:
# :bird: flutter_feathersjs :bird:

Communicate with your feathers js server from flutter.
*__FormData support out the box, auth, reAuth, socketio send event, rest ...__ But event listen via socketio not yet implemented*
Communicate with your feathers js (https://feathersjs.com/) server from flutter.

`Infos: Feathers js is a node framework for real-time applications and REST APIs.`


*__FormData support out the box, auth, reAuth, socketio send event, rest ...__

## Import it

Expand All @@ -22,34 +25,44 @@ FlutterFeathersjs flutterFeathersjs = FlutterFeathersjs()
## Authentication with either with rest or socketio

```dart
// Auth with rest client
// Auth with rest client with email/password [Default strategy is email/password]
var authResponse = await flutterFeathersjs.rest
.authenticate(email: user["email"], password: user["password"]);
.authenticate(userName: user["email"], password: user["password"]);
// Auth with rest client with phone/password
var authResponse = await flutterFeathersjs.rest.authenticate(
strategy: "phone",
userNameFieldName: "tel",
userName: user["tel"],
password: user["password"]);
//Second time, application will restart, just:
var reAuthResponse = await flutterFeathersjs.rest.reAuthenticate();
// Or With socketio
// Note: This must be call after rest auth success
// Not recommanded to use this directly
var authResponse = await flutterFeathersjs.scketio.authWithJWT();
```

## Simplify yor life, Auth both client one time
## Auth both client one time

```dart
// Auth first time with credentials
var authResponse = await flutterFeathersjs.authenticate(email: null, password: null);
var authResponse = await flutterFeathersjs.authenticate(
strategy: "phone",
userNameFieldName: "tel",
userName: user["tel"],
password: user["password"]);
// on App restart, don't disturbe user, just reAuth with with accessToken, early store by FlutterFeathersjs
var reAuthResponse = await flutterFeathersjs.reAuthenticate()
```

## Important
## Contribution

- Listen to event on socketio is not yet implemented
- Documentation is coming
- Contact-me for improvment or contribution purpose
- Example is coming
Loading

0 comments on commit 54e3259

Please sign in to comment.