Skip to content

feat(model-user): add identities

Jure requested to merge user_with_identities into master

This MR aims to bring the @pubsweet/model-user in line with the shared data model, as outlined in: https://gitlab.coko.foundation/pubsweet/types/blob/master/schema.graphql#L150

And in use by: https://gitlab.com/hindawi/xpub/xpub-review/-/blob/develop/packages/component-model/model/identity.js https://gitlab.coko.foundation/xpub/xpub-epmc/blob/master/server/xpub-model/entities/identity/data-access.js https://gitlab.coko.foundation/micropublication/micropublication/blob/master/server/models/identity/identity.model.js https://github.com/elifesciences/elife-xpub/blob/develop/packages/component-model-identity/entities/identity/index.js And others.

There are a number of customisations in place in each of the above implementations, but the basic principle that a User has multiple Identities, which can be local (email/password) or external (e.g. OAuth), is present in all. PubSweet's own model-user does not yet include this and other related concepts, and this MR will introduce them.

Work in progress!

Edited by Jure

Merge request reports